From: Tom Lane <tgl@sss.pgh.pa.us>
To: Rafael Martinez <r.m.guerrero@usit.uio.no>
Cc: Heikki Linnakangas <heikki@enterprisedb.com>
Cc: pgsql-performance@postgresql.org
Subject: Re: Need to run CLUSTER to keep performance
Date: Thu, 08 Nov 2007 10:33:00 -0500
Message-ID: <24775.1194535980@sss.pgh.pa.us> (raw)
In-Reply-To: <47332200.9050705@usit.uio.no>
References: <4732E6B4.1030907@usit.uio.no>
<4732EF07.3060807@enterprisedb.com>
<47332200.9050705@usit.uio.no>
Rafael Martinez <r.m.guerrero@usit.uio.no> writes:
> Heikki Linnakangas wrote:
>> On a small table like that you could run VACUUM every few minutes
>> without much impact on performance. That should keep the table size in
>> check.
> Ok, we run VACUUM ANALYZE only one time a day, every night.
There's your problem.
Reading between the lines I gather that you think an update is "free"
in the sense of not creating a need for vacuum. It's not --- it's
exactly equivalent to an insert + a delete, and it leaves behind a
dead row that needs to be vacuumed. If you do a lot of updates, you
need to vacuum.
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, r.m.guerrero@usit.uio.no, heikki@enterprisedb.com
Subject: Re: Need to run CLUSTER to keep performance
In-Reply-To: <24775.1194535980@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