Re: Database performance post-VACUUM FULL - Mailing list pgsql-performance

From Kevin Grittner
Subject Re: Database performance post-VACUUM FULL
Date
Msg-id 4AC46760020000250002B52E@gw.wicourts.gov
Whole thread Raw
In response to Database performance post-VACUUM FULL  (Karl Wright <kwright@metacarta.com>)
List pgsql-performance
Karl Wright <kwright@metacarta.com> wrote:

> when database maintenance takes place (which consists of a VACUUM
> FULL operation, and some table REINDEX operations)

Besides providing the information requested by Robert, can you explain
why you chose to use VACUUM FULL?  The FULL option is only really
useful in a small set of unusual use cases for recovery from serious
problems.  In most cases it will do more harm than good.  If
autovacuum isn't covering your need by itself, a VACUUM of the
database, usually with the ANALYZE option and *possibly* with the
FREEZE option, is almost always adequate, without resorting to the
pain of VACUUM FULL.

If you've run VACUUM FULL without a REINDEX of *all* indexes *after*
the VACUUM FULL, you've probably seriously bloated your indexes.  You
may also have shuffled around the rows to positions where you're doing
more random access than before.  CLUSTER would be one way to fix both
problems, although if you've bloated your system tables you might be
best off recreating your database with the output from pg_dump..  But
you might want to provide the information Robert requested to confirm
the nature of the problem before attempting to fix it....

-Kevin

pgsql-performance by date:

Previous
From: Claus Guttesen
Date:
Subject: Re: Best suiting OS
Next
From: Tom Lane
Date:
Subject: Re: long running insert statement