Re: Max connections reached without max connections reached - Mailing list pgsql-general

From Tom Lane
Subject Re: Max connections reached without max connections reached
Date
Msg-id 67613.1637709271@sss.pgh.pa.us
Whole thread Raw
In response to Re: Max connections reached without max connections reached  (James Sewell <james.sewell@jirotech.com>)
Responses Re: Max connections reached without max connections reached
List pgsql-general
James Sewell <james.sewell@jirotech.com> writes:
> If I measure from `ps  -ef | grep postgres` and look at the connections
> then I can see that with the startup connections I am hitting this limit.
> So client processes which are listed to the OS as "startup" ARE counted
> towards the 597 connections, but are NOT reported in pg_stat_activity

So I guess the question becomes why are they spending so much time in
the startup state.  That should take mere milliseconds, unless the
clients are being slow to handle the authentication exchange?

I'm also wondering a bit about whether they're being blocked on a lock,
eg. due to something taking an exclusive lock on pg_authid or pg_database.
pg_locks might be interesting to check.

            regards, tom lane



pgsql-general by date:

Previous
From: Adrian Klaver
Date:
Subject: Re: Max connections reached without max connections reached
Next
From: James Sewell
Date:
Subject: Re: Max connections reached without max connections reached