Adriaan Joubert <a.joubert@albourne.com> writes:
> we've suddenly started getting this error message out of postgres
> (7.0.2). Does anybody know where it comes from?
> ERROR: UNLockBuffer: buffer 0 is not locked
Evidently something is passing an invalid buffer number to LockBuffer
in src/backend/storage/buffer/bufmgr.c. (0 is InvalidBuffer, but
LockBuffer won't notice that unless you compiled with asserts enabled.)
Whatever the bug is, it's not directly LockBuffer's fault.
What exactly are you doing that provokes this message?
regards, tom lane