Re: Locks analyze

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, 2023-10-13 at 05:16 +0530, Rajesh Kumar wrote:
> How do I analyze locks and resolve it. Is there only one query that helps?
> This lock issue leading to high connections it seems.

Once you have identified a session that is blocked, get its process ID
from pg_stat_activity and SELECT pg_blocking_pids(12345);
with that process number as argument.

Then you get all the other sessions that block that session.

Yours,
Laurenz Albe






[Index of Archives]     [Postgresql Home]     [Postgresql General]     [Postgresql Performance]     [Postgresql PHP]     [Postgresql Jobs]     [PHP Users]     [PHP Databases]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Databases]     [Yosemite Forum]

  Powered by Linux