| From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
|---|---|
| To: | Bill Moseley <moseley(at)hank(dot)org> |
| Cc: | pgsql-general(at)postgresql(dot)org |
| Subject: | Re: Tracking down a deadlock |
| Date: | 2009-05-02 15:48:21 |
| Message-ID: | 15848.1241279301@sss.pgh.pa.us |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-general |
Bill Moseley <moseley(at)hank(dot)org> writes:
> Not getting any nibbles, so allow me to try a short question:
> If I have a deadlock situation (that will be reported as such by
> Postgresql once the deadlock_timeout passes), does pg_stat_activity
> show the queries that are blocking each other?
In 8.2 or later it should do so; in prior versions there could be some
lag involved. Another thing to keep in mind is that backends like to
cache copies of the pg_stat_activity view --- if you are watching it
to see what is happening, your view is only current as of the start
of your current transaction. Or you can do pgstat_clear_snapshot()
to force collection of new info.
regards, tom lane
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Daniel Verite | 2009-05-02 17:08:00 | Re: Two Questions Re: Warm Backup |
| Previous Message | Thomas Kellerer | 2009-05-02 15:08:00 | Re: Possible to prevent transaction abort? |