[pgpool-general: 8739] Re: Clients disconnection when slave node is off

Tatsuo Ishii ishii at sraoss.co.jp
Fri Apr 14 10:41:38 JST 2023


Hi Jesús,

> Hi Tatsuo,
> 
> At first, thank you so much for your time to investigate this issue.

No problem.

> I have compiled pgpool 4.3.2 with your patch and the problem with pgbench
> is solved.
> I still need to test it in my environment.
> 
> Anyway, I had a look your code and I have seen that the session is closed
> only if failover is not completed in 30 seconds.
> I have the following doubt related to this change. Is this session
> operative during the failover? I mean, if failover spends 20 seconds, is
> this session blocked during this time or this session can accept any
> transaction?

It is likely the session is blocked. The reason for "likely" is the
function which has the logic inside can be called frequently during
session but it is not always. It is possible that a pgpool process
already called the function by the time when failover starts, then
proceeds and sends a query to backend.

> Let me another question. Should we add this issue as a bug?

No you don't need. Developers already recognize this a bug report.

> Thanks in advance.
> 
> Best,
> Jesús
> 
> 
> El mié, 12 abr 2023 3:33, Tatsuo Ishii <ishii at sraoss.co.jp> escribió:
> 
>> > However a downside of this is, while failover clients cannot process
>> > queries or at least slow down processing. Below is the log from
>> > pgbench using "-P 1" option to show progress. As you can see from 170
>> > s pgbench starts to slow down and recovers at 194 s. That is, the
>> > slowdown continued for 24 seconds.
>> >
>>
>> After more research, I suspect the slow down is due to effect of
>> checkpointing. If I add "-S" option to change the transaction time, I
>> don't see the slow down anymore.
>>
>> Best reagards,
>> --
>> Tatsuo Ishii
>> SRA OSS LLC
>> English: http://www.sraoss.co.jp/index_en/
>> Japanese:http://www.sraoss.co.jp
>>


More information about the pgpool-general mailing list