Leonardo F escribió:
> > VACUUM ANALYZE;
> > CLUSTER;
> > REINDEX DATABASE "database";
>
> ANALYZE has to go after CLUSTER; and CLUSTER already
> vacuums the tables (I'm not 100% sure though). CLUSTER also
> reindexes the whole table, so there's no need for another REINDEX.
>
> I think the right
> VACUUM ANALYZE;
> CLUSTER;
> REINDEX DATABASE "database";
ANALYZE has to go after CLUSTER; and CLUSTER already
vacuums the tables (I'm not 100% sure though). CLUSTER also
reindexes the whole table, so there's no need for another REINDEX.
I think the right way of doing it would be:
CLUSTER;
ANA
yes, if you really want to do it - analyze should be running following
cluster, as it moves data around.
plus, with 8.4 autovacuum should do the job.