Re: Autovac vs manual with analyze - Mailing list pgsql-admin

From Alvaro Herrera
Subject Re: Autovac vs manual with analyze
Date
Msg-id 20100315223543.GH3323@alvh.no-ip.org
Whole thread Raw
In response to Re: Autovac vs manual with analyze  (Scott Whitney <scott@journyx.com>)
List pgsql-admin
Scott Whitney wrote:

> So, my questions are:
>
> a) Is the manual vacuum needed for performance reasons, or is auto-vac sufficient?
> b) How do my settings look?
> c) Is there a way that the clogs get cleared via autovac, would a full vac of just template1/template0 (if that last
ispossible) do it?  
>

Autovacuum should be sufficient, provided that the FSM settings are
large enough to hold 20% (plus a bit of slack) of your database total
size in dead tuples.  If they are not, your database starts to bloat and
you need ugly hacks like vacuum full to recover the dead space.

In 8.1, clog is only cleared by database-wide vacuums, which IIRC
autovac doesn't do unless it does a for-Xid-wraparound run, which is not
often.  Probably a weekly database-wide vacuum (not full, i.e. vacuumdb
without -f) is enough.

--
Alvaro Herrera                                http://www.CommandPrompt.com/
The PostgreSQL Company - Command Prompt, Inc.

pgsql-admin by date:

Previous
From: David Jantzen
Date:
Subject: Mixing DBLink versions
Next
From: Tom Lane
Date:
Subject: Re: Mixing DBLink versions