ExclusiveLock without a relation in pg_locks - Mailing list pgsql-general

From Carlos Oliva
Subject ExclusiveLock without a relation in pg_locks
Date
Msg-id 200602231355.IAA13665@pbsi.pbsinet.com
Whole thread Raw
Responses Re: ExclusiveLock without a relation in pg_locks  (Martijn van Oosterhout <kleptog@svana.org>)
Re: ExclusiveLock without a relation in pg_locks  (Michael Fuhr <mike@fuhr.org>)
List pgsql-general

Would connections to a database require crating an extra ExclusiveLock? We have some connections to the database that happen to be “idle in transaction” and their pids have a granted “Exclusive Lock” in pg_locks.  I cannot discern the tables where the ExclusiveLock is being held because the relation field is blank.

 

Moreover, there are other connections to the database coming from the same ip address as that of the connection with the ExclusiveLock.  Some of the pids of these other connections seem to have different kinds of locks (AccessShareL0ck) so I am not quite sure why the pids with the ExclusiveLock’s are necessary.

 

How could I find out the tables that are being locked when I see an “ExclusiveLock” in pg_locks.

pgsql-general by date:

Previous
From: Ragnar
Date:
Subject: Re: Is there a way to check which indexes are being used
Next
From: "pobox@verysmall.org"
Date:
Subject: upgrade PostgreSQL 8.x on production FreeBSD