Re: new autovacuum criterion for visible pages - Mailing list pgsql-hackers

From Masahiko Sawada
Subject Re: new autovacuum criterion for visible pages
Date
Msg-id CAD21AoDyTA_b+OEnaCpXW5twDNx+pb6ufNNCtTyuYL_0zs+i1A@mail.gmail.com
Whole thread Raw
In response to Re: new autovacuum criterion for visible pages  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
On Fri, Aug 12, 2016 at 9:01 AM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
> Michael Paquier <michael.paquier@gmail.com> writes:
>> In short, autovacuum will need to scan by itself the VM of each
>> relation and decide based on that.
>
> That seems like a worthwhile approach to pursue.  The VM is supposed to be
> small, and if you're worried it isn't, you could sample a few pages of it.
> I do not think any of the ideas proposed so far for tracking the
> visibility percentage on-the-fly are very tenable.
>

The one visibility map page can store the information of 32672 heap
pages (255MB), but it would be cost if autovacuum scan whole
visibility map for all tables.
So I think that it's better to provide
autovacuum_vacuum_pagevisible_factor as a relopts.
And the autovacuum scans or samples the visibility map of table that
autovacuum_vacuum_pagevisible_factor is set.

Regards,

--
Masahiko Sawada



pgsql-hackers by date:

Previous
From: Craig Ringer
Date:
Subject: [PATCH] COPY vs \copy HINT
Next
From: Christoph Berg
Date:
Subject: Re: [PATCH] COPY vs \copy HINT