pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Vinubalaji Gopal <vgopal@abaca.com>
To: pgsql-performance@postgresql.org <pgsql-performance@postgresql.org>
Subject: vacuum in Postgresql 8.0.x slowing down the database
Date: Wed, 26 Mar 2008 12:49:56 -0800
Message-ID: <20080326124956.49e1c13d@vinu-ubuntu.abaca> (raw)

Hey all,
   I had posted sometime back asking for the best way to perform vacuum
with a lower priority - I did tune it up to a lower priority
and still noticed that the other database queries are slowing down
with a vacuum on one big table. I also tried to upgrade Postgresql to
8.0.15 as suggested and I still could reproduce the problem.

It happens when I try to vacuum one particular table which has 9.5
million rows and all the other inserts/selects are slowing down by a
factor of 10 times. I am using
vacuum_cost_delay = 100
vacuum_cost_limit = 200

Even if I cancel the vacuum operation or let the vacuum complete - the
slowdown continues to persist till I restart my application.

Whats the best way to analyze the reason Postgresql is slowing down? I
had a look at pg_locks (did not know what to look for) and also tried
starting postgresql with the debug option using: postmaster -d 5
-D /var/pgdata (saw a lot of output including the query being performed
but could not gather anything useful) 

The big table has never been reindexed and has a primary, unique key
with btree index and one foreign key constraint.

--
Vinu



view thread (3+ messages)  latest in thread

Message-ID: <20080326124956.49e1c13d@vinu-ubuntu.abaca>
Permalink:  ../20080326124956.49e1c13d@vinu-ubuntu.abaca/
Also on:    postgresql.org/message-id/20080326124956.49e1c13d@vinu-ubuntu.abaca

 · 

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: vgopal@abaca.com
  Subject: Re: vacuum in Postgresql 8.0.x slowing down the database
  In-Reply-To: <20080326124956.49e1c13d@vinu-ubuntu.abaca>

* 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