Re: [GENERAL] Deadlock in Postgres 8.2

2008-01-21 Thread Reece Hart
On Sun, 2008-01-20 at 16:54 -0500, Greg Smith wrote: > You can look at who has locks on what using pg_locks, see > http://www.postgresql.org/docs/8.2/static/view-pg-locks.html I use the following view to ferret out locking problems. Briefly, look for rows with state='WAIT', then find RUN rows for

Re: [GENERAL] Deadlock in Postgres 8.2

2008-01-20 Thread Greg Smith
On Sun, 20 Jan 2008, Sebastjan Trepca wrote: we are spotting constant deadlocks when altering tables. See http://www.postgresql.org/docs/8.2/interactive/explicit-locking.html for information about the ACCESS EXCLUSIVE lock that ALTER TABLE takes. Anything that is doing that needs to be in as

[GENERAL] Deadlock in Postgres 8.2

2008-01-20 Thread Sebastjan Trepca
Hi, we are spotting constant deadlocks when altering tables. After I restart the db the ALTER TABLE command runs without problems, but when I try to alter some other table later on it deadlocks again. If I kill the process that handles ALTER TABLE the deadlock is "unlocked", but ALTER TABLE still