Re: Auto Vacuum

From: Christopher Browne <cbbrowne(at)acm(dot)org>
To: pgsql-hackers(at)postgresql(dot)org
Subject: Re: Auto Vacuum
Date: 2004-11-30 04:07:18
Message-ID: m3zn10rnd5.fsf@knuth.knuth.cbbrowne.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Oops! pgman(at)candle(dot)pha(dot)pa(dot)us (Bruce Momjian) was seen spray-painting on a wall:
> That could be part of auto-vacuum. Vacuum itself would still
> sequential scan, I think. The idea is to easily grab expire tuples
> when they are most cheaply found.

The nifty handling of this would be to introduce "VACUUM CACHE", which
would simply walk through the shared memory cache to look for expiries
there.

That could have a most interesting interaction with ARC...

On the "unfortunate" side, marking tuples as dead would, I believe
draw in some index pages. (Right?)

Those pages drawn in would remain at the "cheapest" end of the cache;
an ARC 'win.' And it should be the case that this ultimately shrinks
cache usage, as dead tuples get thrown out.

Running VACUUM CACHE periodically on a system that is "killing" tuples
at a pretty steady clip ought to clear out many of those tuples
without needing to browse the tables.

This ought to be particularly helpful with large tables that have
small "contentious" portions that generate dead tuples.
--
let name="cbbrowne" and tld="gmail.com" in name ^ "@" ^ tld;;
http://www.ntlug.org/~cbbrowne/rdbms.html
"Heuristics (from the French heure, "hour") limit the amount of time
spent executing something. [When using heuristics] it shouldn't take
longer than an hour to do something."

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Andrew Dunstan 2004-11-30 04:34:13 Re: multiline CSV fields
Previous Message Robert Treat 2004-11-30 04:01:04 Re: Aubit 4GL for postgresql