pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: meetesh.karia@alumni.duke.edu
Cc: Craig A. James <cjames@modgraph-usa.com>
Cc: pgsql-performance@postgresql.org, "Jean-David Dahan" <jd.dahan@gmail.com>
Subject: Re: Query hanging/not finishing inconsistently
Date: Thu, 22 Jun 2006 20:31:10 -0400
Message-ID: <9336.1151022670@sss.pgh.pa.us> (raw)
In-Reply-To: <fc5b04ca0606201025g7d83548fj7cf0747f0a62dffe@mail.gmail.com>
References: <fc5b04ca0605221020k12c503cfx137980624e78b75@mail.gmail.com>
	<447207C3.8000104@modgraph-usa.com>
	<fc5b04ca0605221340w6e31994ta4ab13efe2f80fe6@mail.gmail.com>
	<fc5b04ca0606201025g7d83548fj7cf0747f0a62dffe@mail.gmail.com>

"Meetesh Karia" <meetesh.karia@gmail.com> writes:
> ... But, once again we ran into the same
> situation where a query that normally executes in ~15ms wouldn't finish.  As
> before, there were no ungranted locks and threads weren't waiting on a
> lock.  I attached gdb to one of the stuck postgres processes and got the
> following stack trace:

> #0  0x008967a2 in _dl_sysinfo_int80 () from /lib/ld-linux.so.2
> #1  0x00977e5b in semop () from /lib/tls/libc.so.6
> #2  0x08167298 in PGSemaphoreLock ()
> #3  0x0818bcb5 in LWLockAcquire ()
> #4  0x080a47f5 in SimpleLruWritePage ()
> #5  0x080a48ad in SimpleLruReadPage ()
> #6  0x080a519a in SubTransGetParent ()
> #7  0x080a51f2 in SubTransGetTopmostTransaction ()
> #8  0x0821371c in HeapTupleSatisfiesSnapshot ()

What I'm wondering about is possible deadlock conditions inside slru.c.
There's no deadlock detection for LWLocks, so if it happened, the
processes involved would just freeze up.

If this happens again, would you collect stack traces from all the stuck
processes, not just one?

			regards, tom lane



view thread (5+ messages)

Message-ID: <9336.1151022670@sss.pgh.pa.us>
Permalink:  ../9336.1151022670@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/9336.1151022670@sss.pgh.pa.us

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-performance@postgresql.org
  Cc: tgl@sss.pgh.pa.us, meetesh.karia@alumni.duke.edu, cjames@modgraph-usa.com, jd.dahan@gmail.com
  Subject: Re: Query hanging/not finishing inconsistently
  In-Reply-To: <9336.1151022670@sss.pgh.pa.us>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox