Re: Call closed: Almost happy ending (from "Data files became huge with no apparent reason" thread)

From: Martijn van Oosterhout <kleptog(at)svana(dot)org>
To: Dario Fumagalli <dfumagalli(at)tin(dot)it>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Call closed: Almost happy ending (from "Data files became huge with no apparent reason" thread)
Date: 2002-09-04 01:55:06
Message-ID: 20020904115506.B22333@svana.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Tue, Sep 03, 2002 at 05:40:25PM +0200, Dario Fumagalli wrote:
> As I stated in an earlier post, i vacuumed was about 2 - 3 weeks earlier
> (my vacation duration).

Seriously, setup a vacuum to run daily. The time wasted by scanning overly
large tables and using inexact statistics far exceeds a once-per-day delay
caused by a vacuum.

> Yes, in this database insert / upate ratio is 1 : 180, and db updates
> are performed 4 times a day by an external PHP console script.

Well, do a vacuum after each update for maximum performance.

I actually had a thought last night. REINDEX recreates the index, probably
with *all* rows in the table, whether or not they are still active. Thus, to
get maximum effect from REINDEX, you need to VACUUM first.

Maybe someone with more knowledge than me can confirm this.
--
Martijn van Oosterhout <kleptog(at)svana(dot)org> http://svana.org/kleptog/
> There are 10 kinds of people in the world, those that can do binary
> arithmetic and those that can't.

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Alvaro Herrera 2002-09-04 03:29:42 Re: [GENERAL] PostgreSQL papers
Previous Message Martijn van Oosterhout 2002-09-04 01:05:25 Re: Columns in views