From: Bruno Wolff III <bruno@wolff.to>
To: Nik <XLPizza@gmail.com>
Cc: pgsql-performance@postgresql.org
Subject: Re: Large Table With Only a Few Rows
Date: Wed, 1 Mar 2006 00:55:56 -0600
Message-ID: <20060301065556.GA1137@wolff.to> (raw)
In-Reply-To: <1141051682.534005.194130@v46g2000cwv.googlegroups.com>
References: <1141051682.534005.194130@v46g2000cwv.googlegroups.com>
On Mon, Feb 27, 2006 at 06:48:02 -0800,
Nik <XLPizza@gmail.com> wrote:
> I have a table that has only a few records in it at the time, and they
> get deleted every few seconds and new records are inserted. Table never
> has more than 5-10 records in it.
>
> However, I noticed a deteriorating performance in deletes and inserts
> on it. So I performed vacuum analyze on it three times (twice in a row,
> and once two days later). In the statistics it says that the table size
> is 863Mb, toast table size is 246Mb, and indexes size is 134Mb, even
> though the table has only 5-10 rows in it it. I was wondering how can I
> reclaim all this space and improve the performance?
You can use VACUUM FULL to recover the space. You should be running normal
VACUUMs on that table every minute or two, not once a day.
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: bruno@wolff.to, XLPizza@gmail.com
Subject: Re: Large Table With Only a Few Rows
In-Reply-To: <20060301065556.GA1137@wolff.to>
* 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