[pgpool-general: 9247] Re: Sporadic health check failures due to authentication failure
Emond Papegaaij
emond.papegaaij at gmail.com
Wed Oct 30 02:03:56 JST 2024
Hi,
We've been running the patch on our testing environment for almost a week
now and haven't seen a single authentication error since the fix. Before
the patch we saw multiple errors on most days. So, I'd say the issue is
fixed.
Best regards,
Emond
Op vr 25 okt 2024 03:17 schreef Tatsuo Ishii <ishii at postgresql.org>:
> > Op do 24 okt 2024 om 07:53 schreef Tatsuo Ishii <ishii at postgresql.org>:
> >
> >> Hi Emond,
> >> > In pool_get_user_credentials in pool_passwd.c (which it must reach
> >> because
> >> > health_check_password is empty), the password file is read via
> passwd_fd.
> >> > This file descriptor is rewound at line 362 (in 4.5.4). However, I
> wonder
> >> > what would happen if another process uses this same descriptor at the
> >> same
> >> > time. I suspect this might lead to one of the two processes (or maybe
> >> even
> >> > both) to get incorrect results.
> >>
> >> I think your analythis is correct. Yes, if multiple process are
> >> reading from the same file descriptor, it could lead to confusing
> >> results. Currently pgpool main process opens the pool_passwd file,
> >> then health check process inherit the file descriptor. This is not
> >> good. Attached is a patch to let the health check process to reopen
> >> the pool_passwd file so that it has it's own file descriptor.
> >>
> >
> > Thank you for the quick response and the patch. I've deployed a patched
> > version of pgpool onto a testing environment, which we will monitor for
> the
> > upcoming week. Until we've verified the patch actually fixes the issue,
> > we'll use the health_check_password setting as a workaround.
>
> OK, I'm looking forward to hearing from you about the testing result.
>
> Best reagards,
> --
> Tatsuo Ishii
> SRA OSS K.K.
> English: http://www.sraoss.co.jp/index_en/
> Japanese:http://www.sraoss.co.jp
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.pgpool.net/pipermail/pgpool-general/attachments/20241029/7739bb40/attachment.htm>
More information about the pgpool-general
mailing list