More log detail on deadlock detection

From: "Burcher, Greg" <Gregory(dot)Burcher(at)netapp(dot)com>
To: <pgsql-general(at)postgresql(dot)org>
Subject: More log detail on deadlock detection
Date: 2011-02-11 20:09:29
Message-ID: 486C9312BAA03A49AB752011C85A275005CF3409@RTPMVEXC1-PRD.hq.netapp.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

I am looking for help in debugging a deadlock situation that occurs
intermittently. I am aware of queries that I can use against system
tables/views such as pg_locks and pg_stat_activity to get good
information about current process statements and locks. However, by the
time postgresql reports deadlock detection, the deadlock loser has
already been selected and the deadlock has been resolved. Thus, the
locks that caused the deadlock are now released.

Is there any way to get complete statement/lock information as of the
time of deadlock, before postgresql resolves the deadlock? The current
log for deadlock reports the last statement for both processes, but not
the granted locks for the processes that caused those statements to
deadlock.

Thanks,

Greg Burcher

burcher(at)netapp(dot)com
<mailto:burcher(at)netapp(dot)com>

Browse pgsql-general by date

  From Date Subject
Next Message Tom Lane 2011-02-11 20:17:51 Re: pg_dump: schema with OID 58698 does not exist
Previous Message David Kerr 2011-02-11 19:52:48 Re: pg_dump: schema with OID 58698 does not exist