Re: [HACKERS] Autovacuum loose ends - Mailing list pgsql-patches

From Alvaro Herrera
Subject Re: [HACKERS] Autovacuum loose ends
Date
Msg-id 20050731233636.GA18237@alvh.no-ip.org
Whole thread Raw
In response to Re: [HACKERS] Autovacuum loose ends  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: [HACKERS] Autovacuum loose ends
List pgsql-patches
Here is another patch for autovacuum:

- vacuum_cost_delay and vacuum_cost_limit can be set per table, as well
  as globally with autovacuum_vacuum_cost_{limit,delay}

- pgstat is reset if recovery is required

- pgstat reset at postmaster start is disabled by default

- Xid-wraparound VACUUM is now FULL without ANALYZE


Note that because of the cost parameters, I changed the vacuum call in a
per-table call instead of passing a list of Oids.  This could be changed
by having two separate lists, one which uses the default values and
other for the rest, but it hardly seems worth the trouble.

(This patch requires catversion bump.)

On Sun, Jul 31, 2005 at 03:15:35PM -0400, Tom Lane wrote:

> BTW, it strikes me that there is one serious error in the current
> autovac logic: it does VACUUM ANALYZE rather than merely VACUUM
> when doing XID-wrap protection.  This means that it actively introduces
> unfrozen tuples into template databases, which is A Bad Move.  We
> should just VACUUM, instead.

True.  Changed in the attached patch.


I think this completes our expectations for 8.1, doesn't it?  Now we
only need the documentation.

--
Alvaro Herrera (<alvherre[a]alvh.no-ip.org>)
"I call it GNU/Linux. Except the GNU/ is silent." (Ben Reiter)

Attachment

pgsql-patches by date:

Previous
From: Tom Lane
Date:
Subject: Re: [HACKERS] Autovacuum loose ends
Next
From: Bruce Momjian
Date:
Subject: Re: [HACKERS] For review: Server instrumentation patch