From: Nikhil S. <ni...@st...> - 2013-03-08 09:23:15
|
> Does it work correctly if gtm/gtm_proxy is not running? Yeah, it does. I faced the same issues that if gtm is down, then the call would error out and the HA infrastructure would wrongly assume that this node is down and do failover. With this simple psql call all that's avoided. Regards, Nikhils >I found > PQping is lighter and easier to use, which is dedicated API to check > if the server is running. It is independent from users/databases and > does not require any password. Just check the target is working. > > I think this is more flexible to be used in various setups. > > Regards; > ---------- > Koichi Suzuki > > > 2013/3/8 Nikhil Sontakke <ni...@st...>: >> I use a simple 'psql -c "\x"' query to monitor coordinator/datanodes. >> The psql call ensures that the connection protocol is followed and >> accepted by that node. It then does an innocuous activity on the psql >> side before exiting. Works well for me. >> >> Regards, >> Nikhils >> >> On Fri, Mar 8, 2013 at 12:48 PM, Koichi Suzuki >> <koi...@gm...> wrote: >>> Okay, here's a patch which uses PQping. This is new to 9.1 and is >>> extremely simple and matches my needs. >>> >>> Regards; >>> ---------- >>> Koichi Suzuki >>> >>> >>> 2013/3/8 Michael Paquier <mic...@gm...>: >>>> >>>> >>>> On Fri, Mar 8, 2013 at 12:13 PM, Koichi Suzuki <koi...@gm...> >>>> wrote: >>>>> >>>>> Because 9.3 merge will not be done in 1.1, I don't think it's feasible >>>>> at present. Second means will be to use PQ* functions. Anyway, >>>>> this will be provided by pgxc_monitor. May be a good idea to use >>>>> custom background, but this could be too much because the requirement >>>>> is very small. >>>> >>>> In this case use something like PQPing or similar, but simply do not involve >>>> core. There would be underlying performance impact for sure. >>>> -- >>>> Michael >>> >>> ------------------------------------------------------------------------------ >>> Symantec Endpoint Protection 12 positioned as A LEADER in The Forrester >>> Wave(TM): Endpoint Security, Q1 2013 and "remains a good choice" in the >>> endpoint security space. For insight on selecting the right partner to >>> tackle endpoint security challenges, access the full report. >>> http://p.sf.net/sfu/symantec-dev2dev >>> _______________________________________________ >>> Postgres-xc-developers mailing list >>> Pos...@li... >>> https://lists.sourceforge.net/lists/listinfo/postgres-xc-developers >>> >> >> >> >> -- >> StormDB - http://www.stormdb.com >> The Database Cloud >> Postgres-XC Support and Service -- StormDB - http://www.stormdb.com The Database Cloud Postgres-XC Support and Service |