<html><head></head><body><div style="font-family:Helvetica Neue, Helvetica, Arial, sans-serif;font-size:16px;"><div><div>I think you can use the if_up_cmd and the if_down_cmd settings in pgpool config.&nbsp;</div><div><br></div><div>When using a VIP, those config normally refer to a script on the system that will add the VIP (or remove) to the network interface.&nbsp; But you can put anything you want into those scripts I guess.</div><div><br></div><div class="ydpd280dd63signature">Pierre</div></div>
            <div><br></div><div><br></div>
            
            <div id="ydp3bbfbc00yahoo_quoted_1475324808" class="ydp3bbfbc00yahoo_quoted">
                <div style="font-family:'Helvetica Neue', Helvetica, Arial, sans-serif;font-size:13px;color:#26282a;">
                    
                    <div>
                        On Wednesday, March 14, 2018, 2:21:04 PM GMT+1, Alexander Dorogensky &lt;amazinglifetime@gmail.com&gt; wrote:
                    </div>
                    <div><br></div>
                    <div><br></div>
                    <div><div id="ydp3bbfbc00yiv7812261398"><div><div dir="ltr"><div class="ydp3bbfbc00yiv7812261398gmail_default" style="font-family:courier new, monospace;">Yes, virtual IP is one way to configure HA but we're currently not using it.</div><div class="ydp3bbfbc00yiv7812261398gmail_default" style="font-family:courier new, monospace;"><br clear="none"></div><div class="ydp3bbfbc00yiv7812261398gmail_default" style="font-family:courier new, monospace;">The two nodes has watchdog enabled. And the watchdog on standby does detect when primary watchdog dies. Is there a callback that runs a script upon this kind of situation?</div><div class="ydp3bbfbc00yiv7812261398gmail_default" style="font-family:courier new, monospace;"><br clear="none"></div><div class="ydp3bbfbc00yiv7812261398gmail_default" style="font-family:courier new, monospace;">The idea is create a mechanism to automatically notify the administrator when one watchdog fails at minimum and to automatically restart pgpool on failed node at best.</div></div><div class="ydp3bbfbc00yiv7812261398yqt3684569236" id="ydp3bbfbc00yiv7812261398yqt56442"><div class="ydp3bbfbc00yiv7812261398gmail_extra"><br clear="none"><div class="ydp3bbfbc00yiv7812261398gmail_quote">On Tue, Mar 13, 2018 at 2:08 PM, Pierre Timmermans <span dir="ltr">&lt;<a shape="rect" href="mailto:ptim007@yahoo.com" rel="nofollow" target="_blank">ptim007@yahoo.com</a>&gt;</span> wrote:<br clear="none"><blockquote class="ydp3bbfbc00yiv7812261398gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"><div><div style="font-family:Helvetica Neue, Helvetica, Arial, sans-serif;font-size:16px;"><div><div>If you set-up the two pgpool nodes in watch-dog mode then yes, the surviving pgpool node will detect when the other node is stopped (via a heartbeat mechanism).&nbsp;</div><div><br clear="none"></div><div>In watchdog mode each pgpool node knows about all the others, one of them is elected as primary. The primary pgpool node acquires the VIP (virtual IP aka delegate_ip in pgpool names).&nbsp; So this is really about making pgpool itself highly available, not to be confused with postgres replication.</div><div><br clear="none"></div><div>The pgpool instances can be on the same servers as postgres or they can be on other servers.</div></div><div><br clear="none"></div><div>Pierre</div>
            <div><br clear="none"></div><div><br clear="none"></div>
            
            <div class="ydp3bbfbc00yiv7812261398m_-6703404147528678035ydp3927c454yahoo_quoted" id="ydp3bbfbc00yiv7812261398m_-6703404147528678035ydp3927c454yahoo_quoted_1291744967">
                <div style="font-family:'Helvetica Neue', Helvetica, Arial, sans-serif;font-size:13px;color:#26282a;"><div><div class="ydp3bbfbc00yiv7812261398h5">
                    
                    <div>
                        On Tuesday, March 13, 2018, 5:15:29 PM GMT+1, Alexander Dorogensky &lt;<a shape="rect" href="mailto:amazinglifetime@gmail.com" rel="nofollow" target="_blank">amazinglifetime@gmail.com</a>&gt; wrote:
                    </div>
                    <div><br clear="none"></div>
                    <div><br clear="none"></div>
                    </div></div><div><div><div class="ydp3bbfbc00yiv7812261398h5"><div id="ydp3bbfbc00yiv7812261398m_-6703404147528678035ydp3927c454yiv4548600200"><div dir="ltr"><div class="ydp3bbfbc00yiv7812261398m_-6703404147528678035ydp3927c454yiv4548600200gmail_default" style="font-family:courier new, monospace;">Hi,</div><div class="ydp3bbfbc00yiv7812261398m_-6703404147528678035ydp3927c454yiv4548600200gmail_default" style="font-family:courier new, monospace;"><br clear="none"></div><div class="ydp3bbfbc00yiv7812261398m_-6703404147528678035ydp3927c454yiv4548600200gmail_default" style="font-family:courier new, monospace;">I have a&nbsp;<span style="color:rgb(34,34,34);font-size:small;font-style:normal;font-weight:400;letter-spacing:normal;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-color:initial;float:none;display:inline;">primary/standby</span> configuration with streaming replication.</div><div class="ydp3bbfbc00yiv7812261398m_-6703404147528678035ydp3927c454yiv4548600200gmail_default" style="font-family:courier new, monospace;">There's two nodes and each node has pgpool.</div><div class="ydp3bbfbc00yiv7812261398m_-6703404147528678035ydp3927c454yiv4548600200gmail_default" style="font-family:courier new, monospace;"><br clear="none"></div><div class="ydp3bbfbc00yiv7812261398m_-6703404147528678035ydp3927c454yiv4548600200gmail_default" style="font-family:courier new, monospace;">When I kill pgpool on primary, does standby gets notified?</div><div class="ydp3bbfbc00yiv7812261398m_-6703404147528678035ydp3927c454yiv4548600200gmail_default" style="font-family:courier new, monospace;"><br clear="none"></div><div class="ydp3bbfbc00yiv7812261398m_-6703404147528678035ydp3927c454yiv4548600200gmail_default" style="font-family:courier new, monospace;">This is not a failover scenario and the failover script doesn't get executed.</div></div></div></div></div>______________________________ _________________<br clear="none">pgpool-general mailing list<br clear="none"><a shape="rect" href="mailto:pgpool-general@pgpool.net" rel="nofollow" target="_blank">pgpool-general@pgpool.net</a><br clear="none"><a shape="rect" href="http://www.pgpool.net/mailman/listinfo/pgpool-general" rel="nofollow" target="_blank">http://www.pgpool.net/mailman/ listinfo/pgpool-general</a><br clear="none"></div>
                </div>
            </div></div></div></blockquote></div><br clear="none"></div></div></div></div></div>
                </div>
            </div></div></body></html>