From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | Dean Toader <deant(at)mirthcorp(dot)com> |
Cc: | pgsql-general(at)postgresql(dot)org |
Subject: | Re: Higher chance of deadlock due to ANALYZE VERBOSE / SHARE UPDATE EXCLUSIVE? |
Date: | 2014-09-23 00:38:25 |
Message-ID: | 1192.1411432705@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
Dean Toader <deant(at)mirthcorp(dot)com> writes:
> Can anyone see an increased possibility of deadlock occurring with
> ANALYZE VERBOSE (initiated by vacuumdb -a --analyze-only --verbose -U postgres
> command run once every 24 hrs on a cronjob schedule), VACUUM (initiated by autovacuum)
> and say ... a long running UPDATE (initiated by a JEE application)
> all happening concurrently on the same table?
If an autovacuum is part of a deadlock, the deadlock detector should
preferentially kill the autovacuum transaction. Is that not happening
for you? But in any case, whether that happens or not, SHARE UPDATE
EXCLUSIVE doesn't block UPDATE commands, so that the case you describe
above is not a deadlock. You would have to be doing some kind of DDL
on the table in question to have any risk.
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Xiang Gan | 2014-09-23 02:26:00 | Re: Installing Postgresql on Linux Friendlyarm |
Previous Message | Dean Toader | 2014-09-22 23:29:53 | Higher chance of deadlock due to ANALYZE VERBOSE / SHARE UPDATE EXCLUSIVE? |