pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Kevin Johnson <Kevin.Johnson@noaa.gov>
To: pgsql-admin@postgresql.org
Cc: Sean Webb <Sean.Webb@noaa.gov>
Subject: Disk space consumed by pk not returned after vacuum or reindex
Date: Wed, 13 Sep 2006 09:53:16 -0400
Message-ID: <45080D4C.2020709@noaa.gov> (raw)

Hello,

I am running into a problem on a RHEL3 systems, running PostgreSQL 7.4

We have a database, which consistently consumes more and more of the 
disk space in it's lvol until it reaches 100%.  So far, we have tried to 
run a full vacuum on the database, with limited success.  Eventually, we 
had to drop and reload the database with the same data inside.  It 
brought the disk usage down to 73%.  It then began to creep once more 
toward 100%.  After some research, I was able to use the pg_class 
catalog to find that the items which are expanding the quickest are 
primary key (btree) indexes.  I attempted to run a REINDEX on one of the 
tables with the pk taking up the largest amount of space.  The usage 
according to pg_class dropped dramatically, however the disk space was 
not returned to the system.  So I attempted another full vacuum 
afterwards, and still nothing was returned to the system.  These tables 
are updated extremely frequently (although their total number of rows is 
close to constant), which is my guess as to why the pk indexes increase 
so rapidly in terms of their disk usage.  Unfortunately, PostgreSQL 
knowledge is limited, and I was wondering if anyone had experienced 
something similar / knows what else we can do to return this disk space 
back to the system?

Thank you in advance for any/all help!

Kevin

Attachments:

Kevin.Johnson.vcf (text/x-vcard, 284B) download begin:vcard fn:Kevin Johnson n:Johnson;Kevin org:Raytheon AWIPS Team adr:SMCC II;;;1325 East West Highway;Silver Spring;MD;20910 email;internet:Kevin.Johnson@noaa.gov title:Sr. Systems Engineer tel;work:301.713.9362 x325 tel;cell:301.787.0648 x-mozilla-html:TRUE version:2.1 end:vcard

view thread (7+ messages)  latest in thread

Message-ID: <45080D4C.2020709@noaa.gov>
Permalink:  ../45080D4C.2020709@noaa.gov/
Also on:    postgresql.org/message-id/45080D4C.2020709@noaa.gov

 · 

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: Kevin.Johnson@noaa.gov, Sean.Webb@noaa.gov
  Subject: Re: Disk space consumed by pk not returned after vacuum or reindex
  In-Reply-To: <45080D4C.2020709@noaa.gov>
  References: <45080D4C.2020709@noaa.gov>

* 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