Обсуждение: WaitOnLock

Поиск
Список
Период
Сортировка

WaitOnLock

От
darcy@druid.net (D'Arcy J.M. Cain)
Дата:
A client just got this error.  Anyone know why I suddenly get this?
The program has been working flawlessly for months before this.

WaitOnLock: error on wakeup - Aborting this transaction

-- 
D'Arcy J.M. Cain <darcy@{druid|vex}.net>   |  Democracy is three wolves
http://www.druid.net/darcy/                |  and a sheep voting on
+1 416 425 1212     (DoD#0082)    (eNTP)   |  what's for dinner.


Re: WaitOnLock

От
Tom Lane
Дата:
darcy@druid.net (D'Arcy J.M. Cain) writes:
> WaitOnLock: error on wakeup - Aborting this transaction

What happens to NOTICEs in your application?

For some odd reason, deadlock reports come out as a NOTICE followed by
this error message; if you are bit-bucketing NOTICEs then you may well
be confused.


Window 1:

regression=# begin;
BEGIN
regression=# lock int4_tbl;
LOCK TABLE

Window 2:

regression=# begin;
BEGIN
regression=# lock int8_tbl;
LOCK TABLE
regression=# lock int4_tbl;
<< waits >>

Window 1:

regression=# lock int8_tbl;
NOTICE:  Deadlock detected -- See the lock(l) manual page for a possible cause.
ERROR:  WaitOnLock: error on wakeup - Aborting this transaction

        regards, tom lane