[pgpool-hackers: 4160] Re: [pgpool-committers: 8599] pgpool: Enhance in stopping pgpool main process.

Tatsuo Ishii ishii at sraoss.co.jp
Sat May 14 14:18:09 JST 2022


I have pushed this to master branch today.

> Enhance in stopping pgpool main process.
> 
> If "pgpool stop" couldn't terminate the main process within certain
> period (currently 5 seconds), send the signal again. The reason why
> pgpool does not accept the stopping signal is not clear at the moment,
> I expect this reduces errors of buildfarm timeout. See if this works.
> 
> Branch
> ------
> master
> 
> Details
> -------
> https://git.postgresql.org/gitweb?p=pgpool2.git;a=commitdiff;h=6d9a2357b722d394384a17694a369907821f98b4
> 
> Modified Files
> --------------
> src/main/main.c | 36 ++++++++++++++++++++++++------------
> 1 file changed, 24 insertions(+), 12 deletions(-)

We occasionally have buidlfarm timeout in some tests. It seems some of
the timeout is caused by that pgpool main process ignores stop signal
(SIGINT). By analyzing the pgpool log, the timeout seems to happen
while failover() is executed. I know that SIGINT is blocked while
executing failover(), but the signal should be re-delivered by the
kernel once failover() finishes. In the buildfarm error cases by some
reason I don't know, it seems the signal is never re-delivered in
those cases.

Currently I haven't find the cause (signal is not re-delivered). So
for a band-aid, I pushed this commit so that the signal is sent
repeatably sent until pgpool stops, in a hope that pgpool receives the
signal while SIGINT is not blocked.

Let me see if I see less timeout error in buildfarm.

Best reagards,
--
Tatsuo Ishii
SRA OSS, Inc. Japan
English: http://www.sraoss.co.jp/index_en.php
Japanese:http://www.sraoss.co.jp


More information about the pgpool-hackers mailing list