Re: PQping command line tool - Mailing list pgsql-hackers

From Bruce Momjian
Subject Re: PQping command line tool
Date
Msg-id 20121003153531.GA3470@momjian.us
Whole thread Raw
In response to PQping command line tool  (Phil Sorber <phil@omniti.com>)
Responses Re: PQping command line tool  (Phil Sorber <phil@omniti.com>)
Re: PQping command line tool  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
On Tue, Oct  2, 2012 at 11:01:36PM -0400, Phil Sorber wrote:
> I was wondering recently if there was any command line tool that
> utilized PQping() or PQpingParams(). I searched the code and couldn't
> find anything and was wondering if there was any interest to have
> something like this included? I wrote something for my purposes of
> performing a health check that also supports nagios style status
> output. It's probably convenient for scripting purposes as well. It's
> not currently ready for submission to a commitfest, but if there was
> an interest I would clean it up so that it would be.

I don't see any tool using PQping except pg_ctl.  Perhaps we should
modify "pg_ctl status" to use PQping.  Right now is only checks the
postmaster.pid file, and checks to see that the pid is a running
postmaster.  What it currently doesn't do is to check if the server is
accepting connections with PQping(), like we do for "pg_ctl -w start".

Comments?

--  Bruce Momjian  <bruce@momjian.us>        http://momjian.us EnterpriseDB
http://enterprisedb.com
 + It's impossible for everything to be true. +



pgsql-hackers by date:

Previous
From: Amit Kapila
Date:
Subject: Re: Switching timeline over streaming replication
Next
From: Phil Sorber
Date:
Subject: Re: PQping command line tool