<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Jul 19, 2017 at 12:07 AM, Shay Cohavi <span dir="ltr">&lt;<a href="mailto:cohavisi@gmail.com" target="_blank">cohavisi@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hi,<div>setting &quot;<span style="color:rgb(0,0,0);font-family:verdana,sans-serif;font-size:13px;font-variant-ligatures:no-common-ligatures">health_check_timeout = 0&quot; has fixed the problem. but why it is set to &quot;20&quot; by default?</span></div></div></blockquote><div><br></div><div>Basically you are hitting some bug in the health check thats why the default value of 20 is causing the problem with your setup. In the normal scenario it should work fine. </div><div>We are looking into the cause and fix for the health_check_timeout issue.</div><div><br></div><div>Thanks</div><div>Best Regards</div><div>Muhammad Usama</div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><span style="color:rgb(0,0,0);font-family:verdana,sans-serif;font-size:13px;font-variant-ligatures:no-common-ligatures"><br></span></div><div><span style="color:rgb(0,0,0);font-family:verdana,sans-serif;font-size:13px;font-variant-ligatures:no-common-ligatures"><br></span></div><div><span style="color:rgb(0,0,0);font-family:verdana,sans-serif;font-size:13px;font-variant-ligatures:no-common-ligatures">Thanks,</span></div><div><span style="color:rgb(0,0,0);font-family:verdana,sans-serif;font-size:13px;font-variant-ligatures:no-common-ligatures">cohavisi</span></div></div><div class="HOEnZb"><div class="h5"><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Jul 17, 2017 at 7:29 PM, Muhammad Usama <span dir="ltr">&lt;<a href="mailto:m.usama@gmail.com" target="_blank">m.usama@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote"><span>On Mon, Jul 17, 2017 at 8:27 PM, Shay Cohavi <span dir="ltr">&lt;<a href="mailto:cohavisi@gmail.com" target="_blank">cohavisi@gmail.com</a>&gt;</span> wrote:<br></span><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">Hi,<div><br></div><span><div>scenario</div><div>server1 - master pgpool + primary postgres</div><div>server2 - slave pgpool + secondary postgres.</div><div><br></div><div>1. server1 (master pgpool + primary postgres) is being poweroff.</div><div>2. server2 is being <span style="font-size:12.8px">successfully escalating to the master Pgpool-II. postgres failover is being triggered (secondary pgpool has been promoted) !!!! pgpool keeps searching for the primary node!!</span></div><div><span style="font-size:12.8px"><br></span></div><div><span style="font-size:12.8px"><br></span></div><div><span style="font-size:12.8px">pgpool log attached...</span></div></span></div></blockquote><div><br></div><div><font face="verdana, sans-serif">As per the logs, Pgpool-II is correctly preforming all the required steps when the it looses the server1, i.e The standby Pgpool-II is successfully promoted to new master Pgpool-II and also the new master Pgpool-II is triggering the failover on the PostgreSQL node (<span style="font-variant-ligatures:no-common-ligatures;color:rgb(0,0,0);font-size:13px"><a href="http://192.168.15.55:5432" target="_blank">192.168.15.55:5432</a></span>) that was located on server1,</font></div><div><font face="verdana, sans-serif">The problem is that after the failover was performed and failover_command was executed by Pgpool-II, The PostgreSQL server <br>







<span style="font-variant-ligatures:no-common-ligatures;color:rgb(0,0,0);font-size:13px"><a href="http://192.168.15.56:5432" target="_blank">192.168.15.56:5432</a></span> becomes unreachable, and Pgpool-II keep looking for primary node, which it is not able to connect to.</font></div><div><font face="verdana, sans-serif"><br></font></div><div><font face="verdana, sans-serif">Do you get any message on <span style="font-variant-ligatures:no-common-ligatures;color:rgb(0,0,0);font-size:13px"><a href="http://192.168.15.56:5432" target="_blank">192.168.15.56:5432</a> </span>PostgreS<wbr>QL server, as why it does not accepts the connection.</font></div><div><font face="verdana, sans-serif"><br></font></div><div><font face="verdana, sans-serif">Also can you perform the same test by disabling the health check timeout (set <span style="font-variant-ligatures:no-common-ligatures;color:rgb(0,0,0);font-size:13px">health_check_timeout = 0), </span></font></div><div><span style="font-variant-ligatures:no-common-ligatures;color:rgb(0,0,0);font-size:13px"><font face="verdana, sans-serif"><br></font></span></div><div><span style="font-variant-ligatures:no-common-ligatures;color:rgb(0,0,0);font-size:13px"><font face="verdana, sans-serif">Thanks</font></span></div><div><span style="font-variant-ligatures:no-common-ligatures;color:rgb(0,0,0);font-size:13px"><font face="verdana, sans-serif">Best Regards</font></span></div><span class="m_-5339619784672677190HOEnZb"><font color="#888888"><div><span style="font-variant-ligatures:no-common-ligatures;color:rgb(0,0,0);font-size:13px"><font face="verdana, sans-serif">Muhammad Usama</font></span></div></font></span><div><div class="m_-5339619784672677190h5">























<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div><span style="font-size:12.8px"><br></span></div><div><span style="font-size:12.8px">Thanks,</span></div><div><span style="font-size:12.8px">cohavisi</span></div></div><div class="m_-5339619784672677190m_7514660867201294323gmail-HOEnZb"><div class="m_-5339619784672677190m_7514660867201294323gmail-h5"><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Jul 17, 2017 at 2:27 PM, Muhammad Usama <span dir="ltr">&lt;<a href="mailto:m.usama@gmail.com" target="_blank">m.usama@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">Hi,<div><br></div><div>There doesn&#39;t seems to be anything wrong with the configuration or cluster design, And if the secondary Pgpool-II is successfully escalating to the master Pgpool-II and acquiring the VIP, It should also perform the backend node failover without any problem.</div><div><br></div><div>Can you please elaborate the situation what actually is the behaviour of Pgpool-II after the server1 failure.</div><div><br></div><div>1- Does Pgpool-II (on server 2) performs the backend failover but it does not promotes the standby PostgreSQL to primary?</div><div>2 - Or is it the case where Pgpool-II never performs the failover.</div><div><br></div><div>Also It would be really helpful if you can share the pgpool log file when this situation occurs.</div><div><div class="gmail_extra"><br></div><div class="gmail_extra">Thanks</div><div class="gmail_extra">Best regards</div><span class="m_-5339619784672677190m_7514660867201294323gmail-m_4702843696114666599HOEnZb"><font color="#888888"><div class="gmail_extra">Muhammad Usama</div></font></span><div class="gmail_extra"><br><div class="gmail_quote"><div><div class="m_-5339619784672677190m_7514660867201294323gmail-m_4702843696114666599h5">On Fri, Jul 14, 2017 at 9:56 PM, Shay Cohavi <span dir="ltr">&lt;<a href="mailto:cohavisi@gmail.com" target="_blank">cohavisi@gmail.com</a>&gt;</span> wrote:<br></div></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div><div class="m_-5339619784672677190m_7514660867201294323gmail-m_4702843696114666599h5"><div dir="ltr">Hi,<div>I have 2 postgres servers (postgres 9.3.5) installed with pgpool(3.6.4) on the same node.</div><div><br></div><div><br></div><div>server1 192.168.15.55</div><div>server 2 192.168.15.56</div><div>pgpool vip 192.168.15.59</div><div><br></div><div><br></div><div><br></div><div><img src="cid:ii_j5440tpw2_15d420772c4ababb" width="544" height="408">​<br></div><div><br></div><div><br></div><div># psql -U postgres -h 192.168.15.59 -p 9999 -c &#39;show pool_nodes&#39;<br></div><div><div> node_id |   hostname    | port | status | lb_weight |  role   | select_cnt | load_balance_node | replication_delay</div><div>---------+---------------+----<wbr>--+--------+-----------+------<wbr>---+------------+-------------<wbr>------+-------------------</div><div> 0       | 192.168.15.55 | 5432 | up     | 0.500000  | primary | 3718       | true              | 0</div><div> 1       | 192.168.15.56 | 5432 | up     | 0.500000  | standby | 0          | false             | 0</div></div><div><br></div><div><br></div><div><br></div><div>my question is about disaster recovery scenario:</div><div><br></div><div>1. <b>&quot;primary postgres&quot; and the &quot;master pgpool&quot; is on server1</b> . pgpool vip established on this node (192.168.15.59)</div><div><br></div><div>2. server1 went down due to  power break. (server1 is dead!!!)</div><div><br></div><div>3. pgpool on server server2 get promoted (vip established 192.168.15.59) .</div><div><br></div><div><span style="background-color:rgb(255,255,255)"><font color="#ff0000">4. NO postgres failover action occurs by the pgpool. pgpool keeps searching for primary postgres with no success.</font></span></div><div><br></div><div>should the new master pgpool execute an failover action(promote) to the slave postgres ??</div><div><br></div><div><br></div><div><br></div><div>Thanks,</div><div>cohavisi </div></div>
<br></div></div><span>______________________________<wbr>_________________<br>
pgpool-general mailing list<br>
<a href="mailto:pgpool-general@pgpool.net" target="_blank">pgpool-general@pgpool.net</a><br>
<a href="http://www.pgpool.net/mailman/listinfo/pgpool-general" rel="noreferrer" target="_blank">http://www.pgpool.net/mailman/<wbr>listinfo/pgpool-general</a><br>
<br></span></blockquote></div><br></div></div></div>
</blockquote></div><br></div>
</div></div></blockquote></div></div></div><br></div></div>
</blockquote></div><br></div>
</div></div></blockquote></div><br></div></div>