<div dir="ltr">Hello <span style="font-family:arial,sans-serif;font-size:13px;white-space:nowrap">Yugo,</span><div><span style="font-family:arial,sans-serif;font-size:13px;white-space:nowrap"><br></span></div><div><font face="arial, sans-serif"><span style="white-space:nowrap">no worries, your replies are much appreciated :)</span></font></div>

<div><font face="arial, sans-serif"><span style="white-space:nowrap"><br></span></font></div><div><font face="arial, sans-serif"><span style="white-space:nowrap">The problem was in the recovery process on a remotely failed node. If I can remember clearly, scp operation asked for </span></font></div>

<div><span style="white-space:nowrap;font-family:arial,sans-serif">host authorisation ("yes/no") and hung the script. </span><span style="white-space:nowrap;font-family:arial,sans-serif">A more verbose message providing clues to pinpoint the problem quickly </span></div>

<div><span style="white-space:nowrap;font-family:arial,sans-serif">would be really great.</span></div><div><span style="white-space:nowrap;font-family:arial,sans-serif"><br></span></div><div><span style="white-space:nowrap;font-family:arial,sans-serif">I updated to pgpoolAdmin 3.3.1 and pgpool 3.3.3. and have noticed an issue:</span></div>

<div><span style="white-space:nowrap;font-family:arial,sans-serif">1. If I update pgpool.conf via pgpoolAdmin, it erases </span>wd_lifecheck_method, wd_interval, wd_heartbeat_port, wd_heartbeat_keepalive entries. </div><div>
<div><span style="background-color:rgb(248,248,255);color:rgb(0,0,0);font-family:monospace;font-size:x-small">2014-04-11 10:38:59 ERROR: pid 32410: pool_config: wd_lifecheck_method must be either "heartbeat" or "query"</span></div>
<span style="color:rgb(0,0,0);font-family:monospace;font-size:x-small;background-color:rgb(248,248,255)">2014-04-11 10:38:59 ERROR: pid 32410: Unable to get configuration. Exiting...</span><br></div><div>I have to go to edit them in file. Does it occur to anyone else?</div>
<div><span style="white-space:nowrap;font-family:arial,sans-serif"><br></span></div><div><font face="arial, sans-serif"><span style="white-space:nowrap">pgpoolAdmin questions:</span></font></div><div><font face="arial, sans-serif"><span style="white-space:nowrap">1. Could you please explain me, what disconnect/return button should do? I assumed, that it would invoke failover/failback functionality. </span></font></div>
<div><font face="arial, sans-serif"><span style="white-space:nowrap">E.g. I could "disconnect" server and then on "return" it would resynchronise with the cluster automatically (cia pcp_recovery_node).</span></font></div>
<div><font face="arial, sans-serif"><span style="white-space:nowrap"><br></span></font></div><div><font face="arial, sans-serif"><span style="white-space:nowrap">If my assumptions are wrong, is it possible to call pcp_recovery_node via interface?</span></font></div>
<div><font face="arial, sans-serif"><span style="white-space:nowrap"><br></span></font></div><div><font face="arial, sans-serif"><span style="white-space:nowrap">2. I could not find any documentation how to enable stop/start/restart buttons in pgpoolAdmin. Currently they are disabled. </span></font></div>
<div><font face="arial, sans-serif"><span style="white-space:nowrap">I am not certain what settings should enable this.</span></font></div><div><font face="arial, sans-serif"><span style="white-space:nowrap"><br>
</span></font></div><div>Thanks for your patience! :)</div><div><br></div><div>Cheers,</div><div>Gintautas</div><div><br></div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Thu, Apr 10, 2014 at 8:38 AM, Yugo Nagata <span dir="ltr"><<a href="mailto:nagata@sraoss.co.jp" target="_blank">nagata@sraoss.co.jp</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Gintautas,<br>
<br>
I'm sorry for replying late.<br>
<br>
Recovery scripts are executed by PostgreSQL, so clues would be in log outputs<br>
of backend server. Does the scripts have the permission to be executed by<br>
postgres user?<br>
<div class=""><br>
On Sat, 29 Mar 2014 19:35:32 +0000<br>
Gintautas Sulskus <<a href="mailto:gingaz@gmail.com">gingaz@gmail.com</a>> wrote:<br>
<br>
> Hi Yugo,<br>
><br>
> thanks for clarifying! Set up is working.<br>
><br>
> I guess that a environment variable defiend in /etc/enviromment is reffered<br>
> > in pg_ni_up.sh but this doesn't work well, right?<br>
><br>
><br>
> > How about to try 'echo $PATH > /tmp/test ' in pg_ni_up.sh?<br>
> > Is the $PATH (or other value) defined in /etc/environment output to<br>
> > /tmp/test or not?<br>
><br>
><br>
>  Even $PATH was not displayed correctly. I presume it was issue with<br>
> permissions, although it is not entirely clear to me what has caused this<br>
> issue.<br>
><br>
><br>
> I am still struggling with pgpool configuration though. Hopefully it is the<br>
> last question. Could please anyone give any clues on this problem:<br>
><br>
> I have tested my online recovery steps (1st and 2nd recovery) by manually<br>
> running scripts. They work just fine. Everything gets logged properly.<br>
><br>
> However, when I try to run pcp_recovery_node -d I get:<br>
> DEBUG: send: tos="R", len=46<br>
> DEBUG: recv: tos="r", len=21, data=AuthenticationOK<br>
> DEBUG: send: tos="D", len=6<br>
> DEBUG: recv: tos="e", len=20, data=recovery failed<br>
> DEBUG: command failed. reason=recovery failed<br>
> BackendError<br>
> DEBUG: send: tos="X", len=4<br>
><br>
</div>> *pgpool log output:*<br>
<div class="">> (pgpool started in debug mode with debug_level=10)<br>
> CHECKPOINT in the 1st stage done<br>
> starting recovery command: "SELECT pgpool_recovery('pg_1st_recovery',<br>
> 'failed_node_ip_address', '/data/postgres/main/')"<br>
> exec_recovery: pg_1st_recovery command failed at 1st stage<br>
><br>
</div>> *pg_1st_recovery logs:*<br>
> none<br>
><br>
> *my pgpool configuration:*<br>
<div class="HOEnZb"><div class="h5">> recovery_1st_stage_command=pg_1st_recovery<br>
> (I expect $1 $2 $3 parameters from pgpool as in examples)<br>
><br>
> Could you please give me any hints what could be wrong?<br>
> Even a rough direction instead of "BackendError" would be extremely<br>
> valuable.<br>
><br>
> Thanks,<br>
> Gintas<br>
><br>
><br>
> On Wed, Mar 26, 2014 at 7:02 AM, Yugo Nagata <<a href="mailto:nagata@sraoss.co.jp">nagata@sraoss.co.jp</a>> wrote:<br>
><br>
> > Hi,<br>
> ><br>
> > On Fri, 21 Mar 2014 00:55:51 +0000<br>
> > Gintautas Sulskus <<a href="mailto:gingaz@gmail.com">gingaz@gmail.com</a>> wrote:<br>
> ><br>
> > > Hello,<br>
> > ><br>
> > > more problems regarding watchdog:<br>
> > > On one of the servers I see a log entry: "wd_create_hb_send_socket:<br>
> > > setsockopt(SO_BINDTODEVICE) requies root privilege".<br>
> > > Any clues what this may be related to? I assume it's permission problem.<br>
> ><br>
> > You can ignore this message because SO_BINDTODEVICE is not necessary.<br>
> ><br>
> > ><br>
> > > Much appreciated!<br>
> > ><br>
> > > Gintautas<br>
> > ><br>
> > ><br>
> > > On Fri, Mar 21, 2014 at 12:48 AM, Gintautas Sulskus <<a href="mailto:gingaz@gmail.com">gingaz@gmail.com</a><br>
> > >wrote:<br>
> > ><br>
> > > > Hello,<br>
> > > ><br>
> > > > ifconfig_path = '/home/ubuntu/apps/scripts'<br>
> > > > PgpoolAdmin description of ifconfig_path is: The path of a command to<br>
> > > > switch the IP address. I understand it as the path for if_up_cmd<br>
> > > > and if_down_cmd commands.<br>
> > > ><br>
> > > > if_up_cmd = 'pg_ni_up.sh up eth0:1 10.0.1.244 255.255.255.0'<br>
> > > > if_down_cmd = 'pg_ni_up.sh down eth0:1'<br>
> ><br>
> > I guess that a environment variable defiend in /etc/enviromment is reffered<br>
> > in pg_ni_up.sh but this doesn't work well, right?<br>
> ><br>
> > How about to try 'echo $PATH > /tmp/test ' in pg_ni_up.sh?<br>
> > Is the $PATH (or other value) defined in /etc/enviroment output to<br>
> > /tmp/test or not?<br>
> ><br>
> > > ><br>
> > > ><br>
> > > > PS. Is this mailing list the right place to discuss about PgpoolAdmin?<br>
> > > > In the latest PgpoolAdmin version "if_*up*_cmd " is described as "The<br>
> > > > command to bring *down* the virtual IP" and "if_*down*_cmd" as "The<br>
> > > > command to bring *up* the virtual IP". Clearly descriptions are mixed<br>
> > up.<br>
> > > ><br>
> > > > Gintautas<br>
> > > ><br>
> > > ><br>
> > > > On Mon, Mar 10, 2014 at 2:46 AM, Yugo Nagata <<a href="mailto:nagata@sraoss.co.jp">nagata@sraoss.co.jp</a>><br>
> > wrote:<br>
> > > ><br>
> > > >> Hi,<br>
> > > >><br>
> > > >> On Sun, 9 Mar 2014 03:00:52 +0000<br>
> > > >> Gintautas Sulskus <<a href="mailto:gingaz@gmail.com">gingaz@gmail.com</a>> wrote:<br>
> > > >><br>
> > > >> > Hello,<br>
> > > >> ><br>
> > > >> > I am trying to set up pgpool watchdog. For virtual IP control my<br>
> > plan<br>
> > > >> is to<br>
> > > >> > use bash scripts (if_up_cmd/if_down_cmd). In my script I use some<br>
> > > >> > environment variables.<br>
> > > >> ><br>
> > > >> > A strange thing occurs here. No matter under what user I run pgpool,<br>
> > > >> script<br>
> > > >> > can't pick up my custom environment variables from /etc/environment<br>
> > > >> > (including customised PATH). It still sees standard binaries like<br>
> > > >> ifconfig<br>
> > > >> > though.<br>
> > > >><br>
> > > >> How do you configure pgpool.conf about if_up_cmd, if_down_cmd,<br>
> > > >> ifconfig_path?<br>
> > > >> pgpool see ifconfig commands on the path specified by these options.<br>
> > > >><br>
> > > >> ><br>
> > > >> > Same script, when run manually by me, works under all users. Any<br>
> > ideas<br>
> > > >> what<br>
> > > >> > can be wrong?<br>
> > > >> ><br>
> > > >> > The only solution I have come up is to redefine env variables in the<br>
> > > >> script.<br>
> > > >> ><br>
> > > >> > Thanks.<br>
> > > >> ><br>
> > > >> > Best Regards,<br>
> > > >> > Gintas<br>
> > > >><br>
> > > >><br>
> > > >> --<br>
> > > >> Yugo Nagata <<a href="mailto:nagata@sraoss.co.jp">nagata@sraoss.co.jp</a>><br>
> > > >><br>
> > > ><br>
> > > ><br>
> > > ><br>
> > > > --<br>
> > > > Best Regards,<br>
> > > > Gintautas Sulskus<br>
> > > ><br>
> > ><br>
> > ><br>
> > ><br>
> > > --<br>
> > > Best Regards,<br>
> > > Gintautas Sulskus<br>
> ><br>
> ><br>
> > --<br>
> > Yugo Nagata <<a href="mailto:nagata@sraoss.co.jp">nagata@sraoss.co.jp</a>><br>
> ><br>
><br>
><br>
><br>
> --<br>
> Best Regards,<br>
> Gintautas Sulskus<br>
<br>
<br>
</div></div><span class="HOEnZb"><font color="#888888">--<br>
Yugo Nagata <<a href="mailto:nagata@sraoss.co.jp">nagata@sraoss.co.jp</a>><br>
</font></span></blockquote></div><br><br clear="all"><div><br></div>-- <br>Best Regards,<br>Gintautas Sulskus
</div>