Re: Vacuumdb error - Mailing list pgsql-general

From Tom Lane
Subject Re: Vacuumdb error
Date
Msg-id 16734.1302799575@sss.pgh.pa.us
Whole thread Raw
In response to Re: Vacuumdb error  (Carl von Clausewitz <clausewitz45@gmail.com>)
Responses Re: Vacuumdb error
List pgsql-general
Carl von Clausewitz <clausewitz45@gmail.com> writes:
> Maintenance:
> #!/bin/sh
> date >> /var/log/postgresql_maintenance.log
> /usr/local/bin/reindexdb --all --username=cvc >>
> /var/log/postgresql_maintenance.log
> echo "Reindex done" >> /var/log/postgresql_maintenance.log
> /usr/local/bin/vacuumdb --all --full --analyze --username=cvc >>
> /var/log/postgresql_maintenance.log
> echo "Vacuum done" >> /var/log/postgresql_maintenance.log

Just FYI, the reindex step is 100% useless if you're going to do a
vacuum full afterwards.

Before 9.0 there was some value in doing vacuum full and then reindex,
but none whatsoever in the other ordering.  As of 9.0 there's just no
point at all in doing both.  VACUUM FULL rebuilds the indexes anyway.

            regards, tom lane

pgsql-general by date:

Previous
From: Carl von Clausewitz
Date:
Subject: Re: Vacuumdb error
Next
From: Carl von Clausewitz
Date:
Subject: Re: Vacuumdb error