Re: VACUUM vs VACUUM ANALYZE

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: VACUUM vs VACUUM ANALYZE
Дата
Msg-id 9081.1003455271@sss.pgh.pa.us
обсуждение исходный текст
Ответ на VACUUM vs VACUUM ANALYZE  ("Mark Coffman" <mark@epilogue.net>)
Список pgsql-general
"Mark Coffman" <mark@epilogue.net> writes:
> I do a

> VACUUM
> VACUUM ANALYZE

> every hour... it takes about 3 minutes to run both.  Should I run ANALYZE
> less often?

VACUUM ANALYZE is a superset of VACUUM; there's certainly no reason to
do both one after the other.

As to whether you should do plain VACUUM some hours and VACUUM ANALYZE
others, that depends --- how fast are the statistics of your data
changing?  If the stats (such as column minimum and maximum values) are
relatively stable, you could get away with fewer ANALYZEs.  Maybe do one
ANALYZE every night at an off-peak time, and just plain VACUUM the rest
of the day.

            regards, tom lane

В списке pgsql-general по дате отправления:

Предыдущее
От: Bruce Momjian
Дата:
Сообщение: Re: To Postgres Devs : Wouldn't changing the select limit
Следующее
От: "Brett W. McCoy"
Дата:
Сообщение: Re: Possible bug in postgresql-7.1.3-1PGDG