From: Tom Lane <tgl@sss.pgh.pa.us>
To: Litao Wu <litaowu@yahoo.com>
Cc: pgsql-performance@postgresql.org
Subject: Re: reindex and copy - deadlock?
Date: Tue, 08 Jun 2004 12:47:08 -0400
Message-ID: <2960.1086713228@sss.pgh.pa.us> (raw)
In-Reply-To: <20040608153106.61670.qmail@web13123.mail.yahoo.com>
References: <20040608153106.61670.qmail@web13123.mail.yahoo.com>
Litao Wu <litaowu@yahoo.com> writes:
> We often experience with the problem that reindex
> cannot be finished in our production database.
> It's typically done with 30 minutes. However,
> sometimes, when there is another "COPY" process,
> reindex will not finish. By monitoring the CPU
> time reindex takes, it does not increase at all.
> That seems a deadlock.
There is no deadlock visible in your report: the reindex process is not
waiting for a lock, according to either ps or pg_locks. You sure it's
not just slow? I'd expect reindex to be largely I/O bound, so the lack
of CPU activity doesn't prove much.
If you think it's actually stuck waiting for something, try attaching to
the REINDEX backend process with gdb to get a stack trace. That would
at least give some idea what it's waiting for.
regards, tom lane
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, litaowu@yahoo.com
Subject: Re: reindex and copy - deadlock?
In-Reply-To: <2960.1086713228@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