Re: Re: [HACKERS] 答复: [HACKERS] postgres 1 个(共 2 个) can pg 9.6 vacuum freeze skip page on index? - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Re: [HACKERS] 答复: [HACKERS] postgres 1 个(共 2 个) can pg 9.6 vacuum freeze skip page on index?
Date
Msg-id 28906.1480617566@sss.pgh.pa.us
Whole thread Raw
In response to Re: [HACKERS] 答复: [HACKERS] postgres 1 个(共 2 个) can pg 9.6 vacuum freeze skip page on index?  (Robert Haas <robertmhaas@gmail.com>)
Responses Re: [HACKERS] Re: [HACKERS] 答复: [HACKERS] postgres 1 个(共 2 个) can pg 9.6 vacuum freeze skip page on index?  (Robert Haas <robertmhaas@gmail.com>)
List pgsql-hackers
Robert Haas <robertmhaas@gmail.com> writes:
> I think that the indexes only need to be scanned if the VACUUM finds
> dead tuples.  But even 1 dead tuple will cause a complete scan of
> every index.  I've complained about this before and I think there's
> room for improvement here, but nobody's been motivated enough to
> pursue this yet.

The thing that's been speculated about in the past is having some
threshold larger than 1 on the minimum number of dead tuples needed
to cause a cleanup pass.  It wouldn't be hard to implement, if you
could get consensus on what the threshold should be.  I'd think
some algorithm similar to the autovacuum thresholds might be
appropriate.  It's not quite clear how this would interact with
HOT pruning, though.

            regards, tom lane



pgsql-hackers by date:

Previous
From: Robert Haas
Date:
Subject: Re: [HACKERS] 答复: [HACKERS] postgres 1 个(共 2 个) can pg 9.6 vacuum freeze skip page on index?
Next
From: Robert Haas
Date:
Subject: Re: [HACKERS] Re: [HACKERS] 答复: [HACKERS] postgres 1 个(共 2 个) can pg 9.6 vacuum freeze skip page on index?