<div dir="ltr"><div class="gmail_default" style="font-family:verdana,sans-serif">Thanks Yugo,</div><div class="gmail_default" style="font-family:verdana,sans-serif">there was some inconsistencies in my network configuration.</div><div class="gmail_default" style="font-family:verdana,sans-serif"><br></div><div class="gmail_default" style="font-family:verdana,sans-serif">Bye.</div><div class="gmail_default" style="font-family:verdana,sans-serif"><br></div><div class="gmail_default" style="font-family:verdana,sans-serif">Meph</div></div><div class="gmail_extra"><br><div class="gmail_quote">On 9 April 2015 at 07:34, 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,<br>
<br>
Second pgpool-II tried to become active and bring up VIP,<br>
but the VIP was brought up by the first pgpool-II, then failed<br>
to start up.<br>
<br>
Can postgres-1 and postgres-2 servers comunicate with each other<br>
on 9000 port? The second pgpool-II might fail to find the other<br>
pgpool.<br>
<br>
If there is no problem with network comunication, starting the<br>
second pgpool-II with a few seconds interval might resolve this.<br>
When the inteval is too short, the first pgpool-II's watchdog<br>
can not be ready to accept standby pgpool-II.<br>
<div class="HOEnZb"><div class="h5"><br>
On Wed, 8 Apr 2015 14:13:45 +0200<br>
Mephysto <<a href="mailto:mephystoonhell@gmail.com">mephystoonhell@gmail.com</a>> wrote:<br>
<br>
> Hi there,<br>
> I'm still testing pgpool 3.4.1 watchdog. I resolved permission issue for<br>
> ifup and ifdown, but now I am some issues in starting phase of stanby<br>
> pgpool instance.<br>
><br>
> When I start master pgpool I receive this output:<br>
><br>
> 2015-04-08 12:10:01: pid 10402: LOG:  watchdog bringing up delegate IP,<br>
> 'ifconfig up' succeeded<br>
> 2015-04-08 12:10:01: pid 10402: DEBUG:  watchdog standing for master<br>
> 2015-04-08 12:10:01: pid 10402: DETAIL:  send the packet to declare the new<br>
> master<br>
> 2015-04-08 12:10:01: pid 10402: LOG:  watchdog escalation successful,<br>
> escalated to master pgpool<br>
> 2015-04-08 12:10:01: pid 10402: LOG:  watchdog started<br>
> 2015-04-08 12:10:01: pid 10402: LOG:  pgpool-II successfully started.<br>
> version 3.4.1 (tataraboshi)<br>
><br>
> But, when I star secondary instance, I receive this error:<br>
><br>
> 2015-04-08 14:08:21: pid 19376: DEBUG:  watchdog executing ping<br>
> 2015-04-08 14:08:21: pid 19376: DETAIL:  succeed to ping 192.168.56.249<br>
> 2015-04-08 14:08:21: pid 19376: DEBUG:  watchdog ping<br>
> 2015-04-08 14:08:21: pid 19376: DETAIL:  ping data: PING 192.168.56.249<br>
> (192.168.56.249) 56(84) bytes of data.<br>
><br>
>         --- 192.168.56.249 ping statistics ---<br>
>         3 packets transmitted, 3 received, 0% packet loss, time 2003ms<br>
>         rtt min/avg/max/mdev = 0.412/1.106/1.799/0.566 ms<br>
><br>
> 2015-04-08 14:08:21: pid 19376: FATAL:  failed to initialize watchdog,<br>
> delegate_IP "192.168.56.249" already exists<br>
><br>
><br>
> This is configuration of master instance:<br>
><br>
> #------------------------------------------------------------------------------<br>
> # WATCHDOG<br>
> #------------------------------------------------------------------------------<br>
><br>
> # - Enabling -<br>
><br>
> use_watchdog = on<br>
>                                     # Activates watchdog<br>
>                                     # (change requires restart)<br>
><br>
> # -Connection to up stream servers -<br>
><br>
> trusted_servers = ''<br>
>                                     # trusted server list which are used<br>
>                                     # to confirm network connection<br>
>                                     # (hostA,hostB,hostC,...)<br>
>                                     # (change requires restart)<br>
> ping_path = '/bin'<br>
>                                     # ping command path<br>
>                                     # (change requires restart)<br>
><br>
> # - Watchdog communication Settings -<br>
><br>
> wd_hostname = 'postgres-1'<br>
>                                     # Host name or IP address of this<br>
> watchdog<br>
>                                     # (change requires restart)<br>
> wd_port = 9000<br>
>                                     # port number for watchdog service<br>
>                                     # (change requires restart)<br>
> wd_authkey = ''<br>
>                                     # Authentication key for watchdog<br>
> communication<br>
>                                     # (change requires restart)<br>
><br>
> # - Virtual IP control Setting -<br>
><br>
> delegate_IP = '192.168.56.249'<br>
>                                     # delegate IP address<br>
>                                     # If this is empty, virtual IP never<br>
> bring up.<br>
>                                     # (change requires restart)<br>
> ifconfig_path = '/opt/postgres/pgpool-II/scripts'<br>
>                                     # ifconfig command path<br>
>                                     # (change requires restart)<br>
> if_up_cmd = 'ifup.sh $_IP_$'<br>
>                                     # startup delegate IP command<br>
>                                     # (change requires restart)<br>
> if_down_cmd = 'ifdown.sh'<br>
>                                     # shutdown delegate IP command<br>
>                                     # (change requires restart)<br>
><br>
> arping_path = '/usr/sbin'           # arping command path<br>
>                                     # (change requires restart)<br>
><br>
> arping_cmd = 'sudo arping -U $_IP_$ -w 1'<br>
>                                     # arping command<br>
>                                     # (change requires restart)<br>
><br>
> # - Behaivor on escalation Setting -<br>
><br>
> clear_memqcache_on_escalation = on<br>
>                                     # Clear all the query cache on shared<br>
> memory<br>
>                                     # when standby pgpool escalate to<br>
> active pgpool<br>
>                                     # (= virtual IP holder).<br>
>                                     # This should be off if client connects<br>
> to pgpool<br>
>                                     # not using virtual IP.<br>
>                                     # (change requires restart)<br>
> wd_escalation_command = ''<br>
>                                     # Executes this command at escalation<br>
> on new active pgpool.<br>
>                                     # (change requires restart)<br>
><br>
> # - Lifecheck Setting -<br>
><br>
> # -- common --<br>
><br>
> wd_lifecheck_method = 'query'<br>
>                                     # Method of watchdog lifecheck<br>
> ('heartbeat' or 'query')<br>
>                                     # (change requires restart)<br>
> wd_interval = 10<br>
>                                     # lifecheck interval (sec) > 0<br>
>                                     # (change requires restart)<br>
><br>
> # -- heartbeat mode --<br>
><br>
> wd_heartbeat_port = 9694<br>
>                                     # Port number for receiving heartbeat<br>
> signal<br>
>                                     # (change requires restart)<br>
> wd_heartbeat_keepalive = 2<br>
>                                     # Interval time of sending heartbeat<br>
> signal (sec)<br>
>                                     # (change requires restart)<br>
> wd_heartbeat_deadtime = 30<br>
>                                     # Deadtime interval for heartbeat<br>
> signal (sec)<br>
>                                     # (change requires restart)<br>
> heartbeat_destination0 = 'postgres-2'<br>
>                                     # Host name or IP address of<br>
> destination 0<br>
>                                     # for sending heartbeat signal.<br>
>                                     # (change requires restart)<br>
> heartbeat_destination_port0 = 9694<br>
>                                     # Port number of destination 0 for<br>
> sending<br>
>                                     # heartbeat signal. Usually this is the<br>
>                                     # same as wd_heartbeat_port.<br>
>                                     # (change requires restart)<br>
> heartbeat_device0 = ''<br>
>                                     # Name of NIC device (such like 'eth0')<br>
>                                     # used for sending/receiving heartbeat<br>
>                                     # signal to/from destination 0.<br>
>                                     # This works only when this is not empty<br>
>                                     # and pgpool has root privilege.<br>
>                                     # (change requires restart)<br>
><br>
> #heartbeat_destination1 = 'host0_ip2'<br>
> #heartbeat_destination_port1 = 9694<br>
> #heartbeat_device1 = ''<br>
><br>
> # -- query mode --<br>
><br>
> wd_life_point = 3<br>
>                                     # lifecheck retry times<br>
>                                     # (change requires restart)<br>
> wd_lifecheck_query = 'SELECT 1'<br>
>                                     # lifecheck query to pgpool from<br>
> watchdog<br>
>                                     # (change requires restart)<br>
> wd_lifecheck_dbname = 'template1'<br>
>                                     # Database name connected for lifecheck<br>
>                                     # (change requires restart)<br>
> wd_lifecheck_user = 'postgres'<br>
>                                     # watchdog user monitoring pgpools in<br>
> lifecheck<br>
>                                     # (change requires restart)<br>
> wd_lifecheck_password = ''<br>
>                                     # Password for watchdog user in<br>
> lifecheck<br>
>                                     # (change requires restart)<br>
><br>
> # - Other pgpool Connection Settings -<br>
><br>
> other_pgpool_hostname0 = 'postgres-2'<br>
>                                     # Host name or IP address to connect to<br>
> for other pgpool 0<br>
>                                     # (change requires restart)<br>
> other_pgpool_port0 = 9999<br>
>                                     # Port number for othet pgpool 0<br>
>                                     # (change requires restart)<br>
> other_wd_port0 = 9000<br>
>                                     # Port number for othet watchdog 0<br>
>                                     # (change requires restart)<br>
> #other_pgpool_hostname1 = 'host1'<br>
> #other_pgpool_port1 = 5432<br>
> #other_wd_port1 = 9000<br>
><br>
><br>
> And this is configuration for secondary instance:<br>
><br>
> #------------------------------------------------------------------------------<br>
> # WATCHDOG<br>
> #------------------------------------------------------------------------------<br>
><br>
> # - Enabling -<br>
><br>
> use_watchdog = on<br>
>                                     # Activates watchdog<br>
>                                     # (change requires restart)<br>
><br>
> # -Connection to up stream servers -<br>
><br>
> trusted_servers = ''<br>
>                                     # trusted server list which are used<br>
>                                     # to confirm network connection<br>
>                                     # (hostA,hostB,hostC,...)<br>
>                                     # (change requires restart)<br>
> ping_path = '/bin'<br>
>                                     # ping command path<br>
>                                     # (change requires restart)<br>
><br>
> # - Watchdog communication Settings -<br>
><br>
> wd_hostname = 'postgres-2'<br>
>                                     # Host name or IP address of this<br>
> watchdog<br>
>                                     # (change requires restart)<br>
> wd_port = 9000<br>
>                                     # port number for watchdog service<br>
>                                     # (change requires restart)<br>
> wd_authkey = ''<br>
>                                     # Authentication key for watchdog<br>
> communication<br>
>                                     # (change requires restart)<br>
><br>
> # - Virtual IP control Setting -<br>
><br>
> delegate_IP = '192.168.56.249'<br>
>                                     # delegate IP address<br>
>                                     # If this is empty, virtual IP never<br>
> bring up.<br>
>                                     # (change requires restart)<br>
> ifconfig_path = '/opt/postgres/pgpool-II/scripts'<br>
>                                     # ifconfig command path<br>
>                                     # (change requires restart)<br>
> if_up_cmd = 'ifup.sh $_IP_$'<br>
>                                     # startup delegate IP command<br>
>                                     # (change requires restart)<br>
> if_down_cmd = 'ifdown.sh'<br>
>                                     # shutdown delegate IP command<br>
>                                     # (change requires restart)<br>
><br>
> arping_path = '/usr/sbin'           # arping command path<br>
>                                     # (change requires restart)<br>
><br>
> arping_cmd = 'arping -U $_IP_$ -w 1'<br>
>                                     # arping command<br>
>                                     # (change requires restart)<br>
><br>
> # - Behaivor on escalation Setting -<br>
><br>
> clear_memqcache_on_escalation = on<br>
>                                     # Clear all the query cache on shared<br>
> memory<br>
>                                     # when standby pgpool escalate to<br>
> active pgpool<br>
>                                     # (= virtual IP holder).<br>
>                                     # This should be off if client connects<br>
> to pgpool<br>
>                                     # not using virtual IP.<br>
>                                     # (change requires restart)<br>
> wd_escalation_command = ''<br>
>                                     # Executes this command at escalation<br>
> on new active pgpool.<br>
>                                     # (change requires restart)<br>
><br>
> # - Lifecheck Setting -<br>
><br>
> # -- common --<br>
><br>
> wd_lifecheck_method = 'query'<br>
>                                     # Method of watchdog lifecheck<br>
> ('heartbeat' or 'query')<br>
>                                     # (change requires restart)<br>
> wd_interval = 10<br>
>                                     # lifecheck interval (sec) > 0<br>
>                                     # (change requires restart)<br>
><br>
> # -- heartbeat mode --<br>
><br>
> wd_heartbeat_port = 9694<br>
>                                     # Port number for receiving heartbeat<br>
> signal<br>
>                                     # (change requires restart)<br>
> wd_heartbeat_keepalive = 2<br>
>                                     # Interval time of sending heartbeat<br>
> signal (sec)<br>
>                                     # (change requires restart)<br>
> wd_heartbeat_deadtime = 30<br>
>                                     # Deadtime interval for heartbeat<br>
> signal (sec)<br>
>                                     # (change requires restart)<br>
> heartbeat_destination0 = 'postgres-1'<br>
>                                     # Host name or IP address of<br>
> destination 0<br>
>                                     # for sending heartbeat signal.<br>
>                                     # (change requires restart)<br>
> heartbeat_destination_port0 = 9694<br>
>                                     # Port number of destination 0 for<br>
> sending<br>
>                                     # heartbeat signal. Usually this is the<br>
>                                     # same as wd_heartbeat_port.<br>
>                                     # (change requires restart)<br>
> heartbeat_device0 = ''<br>
>                                     # Name of NIC device (such like 'eth0')<br>
>                                     # used for sending/receiving heartbeat<br>
>                                     # signal to/from destination 0.<br>
>                                     # This works only when this is not empty<br>
>                                     # and pgpool has root privilege.<br>
>                                     # (change requires restart)<br>
><br>
> #heartbeat_destination1 = 'host0_ip2'<br>
> #heartbeat_destination_port1 = 9694<br>
> #heartbeat_device1 = ''<br>
><br>
> # -- query mode --<br>
><br>
> wd_life_point = 3<br>
>                                     # lifecheck retry times<br>
>                                     # (change requires restart)<br>
> wd_lifecheck_query = 'SELECT 1'<br>
>                                     # lifecheck query to pgpool from<br>
> watchdog<br>
>                                     # (change requires restart)<br>
> wd_lifecheck_dbname = 'template1'<br>
>                                     # Database name connected for lifecheck<br>
>                                     # (change requires restart)<br>
> wd_lifecheck_user = 'postgres'<br>
>                                     # watchdog user monitoring pgpools in<br>
> lifecheck<br>
>                                     # (change requires restart)<br>
> wd_lifecheck_password = ''<br>
>                                     # Password for watchdog user in<br>
> lifecheck<br>
>                                     # (change requires restart)<br>
><br>
> # - Other pgpool Connection Settings -<br>
><br>
> other_pgpool_hostname0 = 'postgres-1'<br>
>                                     # Host name or IP address to connect to<br>
> for other pgpool 0<br>
>                                     # (change requires restart)<br>
> other_pgpool_port0 = 9999<br>
>                                     # Port number for othet pgpool 0<br>
>                                     # (change requires restart)<br>
> other_wd_port0 = 9000<br>
>                                     # Port number for othet watchdog 0<br>
>                                     # (change requires restart)<br>
> #other_pgpool_hostname1 = 'host1'<br>
> #other_pgpool_port1 = 5432<br>
> #other_wd_port1 = 9000<br>
><br>
><br>
><br>
><br>
> Can you help to resolve my issue?<br>
><br>
> Thanks in advance.<br>
><br>
> Best regards.<br>
><br>
> Meph<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></div>