Re: Vacuum and inserts

Поиск
Список
Период
Сортировка
От Michael Fuhr
Тема Re: Vacuum and inserts
Дата
Msg-id 20080619141149.GA24935@winnie.fuhr.org
обсуждение исходный текст
Ответ на Vacuum and inserts  (Mark Wilden <mark.wilden@gmail.com>)
Ответы Re: Vacuum and inserts  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-general
On Wed, Jun 18, 2008 at 12:29:46PM -0700, Mark Wilden wrote:
> My coworker and I are having an argument about whether it's necessary
> to VACUUM an insert-only table.
>
> My theory is that since there are no outdated nor deleted rows, VACUUM
> doesn't do anything.

Rolled back transactions on an insert-only table can leave behind
dead rows.  Also, even if the table never has dead rows you still
have to vacuum periodically to prevent transaction ID wraparound.

http://www.postgresql.org/docs/8.3/interactive/routine-vacuuming.html#VACUUM-FOR-WRAPAROUND

"To avoid this, it is necessary to vacuum every table in every
database at least once every two billion transactions."

--
Michael Fuhr

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

Предыдущее
От: "Albretch Mueller"
Дата:
Сообщение: Re: HA best pratices with postgreSQL
Следующее
От: Bill Moran
Дата:
Сообщение: Re: postgres generates too much processes per minute