Jonathan Parkin <jonathan.parkin@legendplc.com> writes:
> I have a reasonably large, live, system-critical database. A perl
> script on another machine connects and issues a sequence of commands in
> a transaction, the last of which is a delete. The delete never returns
> a response, and the connection never times out. The postgres process
> handling the delete is in a scheduled state, but stracing it produces no
> output at all.
Sounds like it's stuck in a tight loop. Can you attach to the postgres
process with gdb and get a stack trace to find out where the loop is?
If this is a specific row causing the issue, then I'd wonder about
data corruption of some sort. It might be worth looking at the
table with pg_filedump (from http://sources.redhat.com/rhdb/).
regards, tom lane