<div dir="ltr"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">> For many of our customers this is unwanted behavior. They would rather see<br>
> the service become unavailable than continue to operate in a split brain. I<br>
> went through the available options on pgpool, but could not find an option<br>
> that would help me here. I'm looking for a way to prevent pgpool from<br>
> accessing its backends with its watchdog is not part of a quorum. Is this<br>
> currently possible in pgpool? If not, is it worth considering adding a<br>
> feature for this?<br>
<br>
One of the difficulties with this kind of approach is, how to decide<br>
that the primary should be killed in a reliable way.<br>
<br>
Suppose we have:<br>
<br>
node 1: pgpool/watchdog 1, primary PostgreSQL<br>
node 2: pgpool/watchdog 2, standby PostgreSQL<br>
node 3: pgpool/watchdog 3, standby PostgreSQL<br>
<br>
The scenario:<br>
<br>
1) Watchdog 1 lost communication to watchdog 2 and watchdog 3. So<br>
   watchdog 1 lost quorum.<br>
<br>
2) However communication between pgpool 1/2 and the primary is still healthy.<br>
<br>
3) Watchdog 1 decides to kill the primary and the primary goes down.<br>
<br>
4) pgpool 1/2 have to promote one of the standbys to create new primary.</blockquote><div><br></div><div>Yes, this always is the issue with communication within a cluster, or more specifically the loss of communication. That's why I wanted to discuss this here. What happens to a VIP in your scenario if watchdog 1 started with the VIP assigned? Will watchdog 1 drop the VIP when it losses the quorum? Is the pgpool 1 still supposed to receive queries when it can no longer be sure it is sending them to the correct database?</div><div><br></div><div>In our setup, what I would ideally see is that I can configure pgpool to not send writes (or completely disconnect all its backends) when the instance is not part of a quorum. Also, it would be really great if I can configure a command when the watchdog status changes. That would allow me to implement custom behavior myself.</div><div><br></div><div>Best regards,</div><div>Emond</div></div></div>