Обсуждение: vacuum on table with all rows frozen

Поиск
Список
Период
Сортировка

vacuum on table with all rows frozen

От
Tom DalPozzo
Дата:
Hi,
let's suppose I have a table which after beign populated with only INSERTs, doesn't receive no more writing queries (neither insert or update or delete). Only reading queries.
Once all table rows get frozen by (auto)vacuum, will a next (auto)vacuum scan that table for any reason or does it understand that it would be useless (as no more rows to mark as forzen and no dead tuples) ?
As I will have hunderds of big tables like that, I want to be sure that the vacuum process doesn't waste time.
Regards
Pupillo




Re: vacuum on table with all rows frozen

От
Adrian Klaver
Дата:
On 04/01/2017 09:09 AM, Tom DalPozzo wrote:
> Hi,
> let's suppose I have a table which after beign populated with only
> INSERTs, doesn't receive no more writing queries (neither insert or
> update or delete). Only reading queries.
> Once all table rows get frozen by (auto)vacuum, will a next (auto)vacuum
> scan that table for any reason or does it understand that it would be
> useless (as no more rows to mark as forzen and no dead tuples) ?

What version of Postgres?

Don't vacuum all-frozen pages.:

https://git.postgresql.org/gitweb/?p=postgresql.git;a=commit;h=fd31cd265138019dcccc9b5fe53043670898bc9f

That made it into 9.6:
https://www.postgresql.org/docs/9.6/static/release-9-6.html

E.3.3.1.6. VACUUM

Avoid re-vacuuming pages containing only frozen tuples (Masahiko Sawada,
Robert Haas, Andres Freund)



> As I will have hunderds of big tables like that, I want to be sure that
> the vacuum process doesn't waste time.
> Regards
> Pupillo
>
>
>
>


--
Adrian Klaver
adrian.klaver@aklaver.com


Re: vacuum on table with all rows frozen

От
Tom DalPozzo
Дата:

2017-04-01 18:34 GMT+02:00 Adrian Klaver <adrian.klaver@aklaver.com>:
On 04/01/2017 09:09 AM, Tom DalPozzo wrote:
Hi,
let's suppose I have a table which after beign populated with only
INSERTs, doesn't receive no more writing queries (neither insert or
update or delete). Only reading queries.
Once all table rows get frozen by (auto)vacuum, will a next (auto)vacuum
scan that table for any reason or does it understand that it would be
useless (as no more rows to mark as forzen and no dead tuples) ?

What version of Postgres?

Don't vacuum all-frozen pages.:

https://git.postgresql.org/gitweb/?p=postgresql.git;a=commit;h=fd31cd265138019dcccc9b5fe53043670898bc9f

That made it into 9.6:
https://www.postgresql.org/docs/9.6/static/release-9-6.html

E.3.3.1.6. VACUUM

Avoid re-vacuuming pages containing only frozen tuples (Masahiko Sawada, Robert Haas, Andres Freund)

Hi,  I was just wondering if... Nice to know now, my version is 9.6
Thank you very much
Pupillo