pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Jeff Boes <jboes@nexcerpt.com>
Cc: pgsql-admin@postgresql.org
Subject: Re: Postgres and mod_perl: table locked during vacuum?
Date: Tue, 18 Jun 2002 09:29:14 -0400
Message-ID: <25605.1024406954@sss.pgh.pa.us> (raw)
In-Reply-To: <aekq55$1p5t$1@news.hub.org>
References: <aekq55$1p5t$1@news.hub.org>

Jeff Boes <jboes@nexcerpt.com> writes:
> We are experiencing a fairly predictable lock-up in the overnight VACUUM
> ANALYZE maintenance script.  The VACUUM gets to the pg_class table and
> then stops, obviously waiting for something else to give up control of
> the table.  The VACUUM script resumes precisely when the web server is
> bounced.  The web server is using mod_perl, and mod_perl uses DBI code
> (in a locally developed module that does establish a connection at
> *compile* time in order to verify existence of tables used in the
> code).

I suppose you're not running 7.2 ?

Turn on debug_print_query and look at the log to see what queries
are being issued.  I'll bet lunch that the webserver code is doing
something like

	begin;
	select * from pg_class where ... ;
	<<go to sleep indefinitely>>

			regards, tom lane



view thread (2+ messages)

Message-ID: <25605.1024406954@sss.pgh.pa.us>
Permalink:  ../25605.1024406954@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/25605.1024406954@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 from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-admin@postgresql.org
  Cc: tgl@sss.pgh.pa.us, jboes@nexcerpt.com
  Subject: Re: Postgres and mod_perl: table locked during vacuum?
  In-Reply-To: <25605.1024406954@sss.pgh.pa.us>
  References: <aekq55$1p5t$1@news.hub.org> <25605.1024406954@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