Skip index cleanup if autovacuum did not do any work

Поиск
Список
Период
Сортировка
Искать
От
Feike Steenbergen
Тема
Skip index cleanup if autovacuum did not do any work
Дата
Msg-id
CAK_s-G114rYyms0ZuYWQG5jP_OHApLHyJo9-Zmmt2z7vqAKcog@mail.gmail.com
Список
Дерево обсуждения
Skip index cleanup if autovacuum did not do any work Feike Steenbergen <feikesteenbergen@gmail.com>
Re: Skip index cleanup if autovacuum did not do any work Tom Lane <tgl@sss.pgh.pa.us>
Re: Skip index cleanup if autovacuum did not do any work Peter Geoghegan <pg@bowt.ie>
Re: Skip index cleanup if autovacuum did not do any work Peter Geoghegan <pg@bowt.ie>
Re: Skip index cleanup if autovacuum did not do any work Feike Steenbergen <feikesteenbergen@gmail.com>
Re: Skip index cleanup if autovacuum did not do any work Peter Geoghegan <pg@bowt.ie>
Re: Skip index cleanup if autovacuum did not do any work Feike Steenbergen <feikesteenbergen@gmail.com>
Re: Skip index cleanup if autovacuum did not do any work Feike Steenbergen <feikesteenbergen@gmail.com>
On a server with a very frequent xid wraparound I can see that the anti-wraparound vacuum is finished very quickly with the heap, yet it still scans all the indexes, which causes it to still have to read a lot of data, which takes a considerable amount of time.

I dove into the code a bit and as far as I can tell, all the time spent for doing this is is in lazy_cleanup_index.

For the very specific use case of all-frozen, basically read-only tables, would it be ok to skip the lazy_cleanup_index call? As we are sure we did not touch the heap or the index, I'd say a cleanup may not be necessary.

For this very specific usecase I would like to discuss whether or not this is
a sane and/or good idea.

regards,

Feike
В списке pgsql-hackers по дате отправления
От: Tom Lane
Дата:
От: Tom Lane
Дата:
Сообщение: Re: pgindent run?
FAQ