[pgpool-general: 6473] Re: trusted_servers

Alexander Dorogensky amazinglifetime at gmail.com
Thu Mar 21 01:12:49 JST 2019


One recovery job on each node I mean.

On Wed, Mar 20, 2019 at 11:12 AM Alexander Dorogensky <
amazinglifetime at gmail.com> wrote:

> Awesome, thanks!
>
> Pgpool-II should still works very well in case of 2 node cluster (
>> although recommended is min 3). And in this case even if the split brain
>> happens it takes just few seconds for watchdog to detect and recover from
>> it. So you can still disable  trusted_servers in your setup.
>
>
> Interesting.. but that was not the case. I had to set that parameter
> because pgpool wasn't detecting network partition and there would be two
> recovery jobs running on both nodes.
>
> On Wed, Mar 20, 2019 at 9:43 AM Muhammad Usama <m.usama at gmail.com> wrote:
>
>>
>> On Wed, Mar 20, 2019 at 7:09 PM Alexander Dorogensky <
>> amazinglifetime at gmail.com> wrote:
>> >
>> > Thanks for a very detailed explanation!
>> >
>> > How long can it take pgpool to detect that the trusted server (one) is
>> not responsive?
>>
>>
>> Pgpool-II issues the ping command "ping -c3 trusted_server" for each
>> server listed in trusted_servers list after every wd_interval seconds, and
>> whenever
>> ping result for every server in the trusted_servers list comes out
>> negative, Pgpool node consider itself as isolated and removes itself from
>> cluster.
>> So effectively it takes maximum wd_interval number of seconds plus 3 ping
>> attempts to detect the trusted_server is not responsive.
>>
>> >
>> > We're using pgpool 3.6.9 and we have 2 node (primary/standby postgres
>> cluster with streaming replication) configuration and each node has pgpool.
>> >
>> > We had to set trusted_servers because otherwise pgpool wouldn't detect
>> network partition events such as when
>> > network interface goes down on one of the nodes. So I believe in this
>> configuration we wouldn't have been able to use
>> > the pgpool's split-brain syndrome auto detection?
>> >
>>
>> Pgpool-II should still works very well in case of 2 node cluster (
>> although recommended is min 3). And in this case even if the split brain
>> happens it takes just few seconds for watchdog to detect and recover from
>> it. So you can still disable  trusted_servers in your setup.
>>
>> Also to protect against network interface going down you can use the
>> interface monitoring in watchdog wd_monitoring_interfaces_list
>> (see *wd_monitoring_interfaces_list* in section 5.14.7 of
>> http://www.pgpool.net/docs/latest/en/html/runtime-watchdog-config.html#CONFIG-WATCHDOG-SERVER-CONFIGURATION
>> )
>>
>>
>> Thanks
>> Best Regards
>> Muhammad Usama
>>
>>
>> >
>> > Thank you Muhammad!
>> >
>> >
>> >
>> >
>> >
>> > On Wed, Mar 20, 2019 at 8:23 AM Muhammad Usama <m.usama at gmail.com>
>> wrote:
>> >>
>> >> Hi
>> >>
>> >> On Wed, Mar 13, 2019 at 6:28 PM Alexander Dorogensky <
>> amazinglifetime at gmail.com> wrote:
>> >>>
>> >>> Hi everyone,
>> >>>
>> >>> We generally set this parameter to one host to remedy split brain
>> situations but some customers have unreliable networks and therefore ping
>> to that host would fail and pgpool would shut down.
>> >>>
>> >>> My understanding was that trusted server(s) connection will only be
>> tested after degenerated state was detected (before triggering failover),
>> is it correct?
>> >>>
>> >>> If not.. how do I configure trusted servers in a flaky network?
>> >>
>> >>
>> >> No thats not correct, If the trusted_server(s) are configured than
>> Pgpool-II try to ping the trusted_servers after every life-check interval
>> (wd_interval),
>> >>
>> >> Basically the trusted_servers checking was introduced in the pgpool
>> watchdog, during the early days of watchdog, and as you mentioned its
>> purpose was to
>> >> mitigate the split-brain syndrome, by making sure that the Pgpool-II
>> node which gets isolated from the network because of network partitioning or
>> >> some other network issue removes itself from the Pgpool-II cluster.
>> >>
>> >> But since Pgpool-II 3.5 there have been lots of enhancements made to
>> the Pgpool-II watchdog specifically in the area of guarding against the
>> split-brain and
>> >> other similar scenarios, and the latest versions of Pgpool-II does not
>> require trusted_servers configuration to detect and avoid split-brain.
>> >>
>> >> So if you are using the Pgpool-II > V 3.5 and the Pgpool-II cluster is
>> configured with odd number of nodes (>=3) than you can safely disable the
>> trusted_server
>> >> configuration, and watchdog will take care of split-brain issue itself.
>> >>
>> >> Thanks
>> >> Best Regards
>> >> Muhammad Usama
>> >>
>> >>
>> >>>
>> >>> Thanks
>> >>> _______________________________________________
>> >>> pgpool-general mailing list
>> >>> pgpool-general at pgpool.net
>> >>> http://www.pgpool.net/mailman/listinfo/pgpool-general
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.sraoss.jp/pipermail/pgpool-general/attachments/20190320/03f234db/attachment.html>


More information about the pgpool-general mailing list