Re: Delays between "connection received" and "connection authenticated" because of localhost entries in hba
Tom Lane <tgl@sss.pgh.pa.us>
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Greg Sabino Mullane <htamfids@gmail.com>
Cc: "Daniel Westermann (DWE)" <daniel.westermann@dbi-services.com>,
Laurenz Albe <laurenz.albe@cybertec.at>,
"pgsql-general@lists.postgresql.org"
<pgsql-general@lists.postgresql.org>
Date: 2024-10-30T14:49:15Z
Lists: pgsql-general
Greg Sabino Mullane <htamfids@gmail.com> writes: > I'd echo the suggestion to strace this. You can use the pre_auth_delay > setting to help facilitate that. See: IIUC, the delays are rare and unpredictable, so that strace'ing seems unlikely to be practical. If rebuilding from source is feasible, you could insert monitoring elog(LOG) calls around the name lookup (that is, around the pg_getnameinfo_all call in src/backend/libpq/hba.c). This would confirm or disprove the theory that the name lookup is the source of the issue, which is about as much as we'd get out of strace. regards, tom lane