pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Simon Riggs <simon@2ndQuadrant.com>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Heikki Linnakangas <heikki.linnakangas@enterprisedb.com>
Cc: PostgreSQL-development <pgsql-hackers@postgresql.org>
Subject: Re: Visibility map, partial vacuums
Date: Tue, 28 Oct 2008 18:07:17 +0000
Message-ID: <1225217237.3971.225.camel@ebony.2ndQuadrant> (raw)
In-Reply-To: <9966.1225216692@sss.pgh.pa.us>
References: <4905AE17.7090305@enterprisedb.com>
	<1225213395.3971.217.camel@ebony.2ndQuadrant>
	<9966.1225216692@sss.pgh.pa.us>


On Tue, 2008-10-28 at 13:58 -0400, Tom Lane wrote:
> Simon Riggs <simon@2ndQuadrant.com> writes:
> > On Mon, 2008-10-27 at 14:03 +0200, Heikki Linnakangas wrote:
> >> Lazy VACUUM only needs to visit pages that are '0' in the visibility 
> >> map. This allows partial vacuums, where we only need to scan those parts 
> >> of the table that need vacuuming, plus all indexes.
> 
> > Just realised that this means we still have to visit each block of a
> > btree index with a cleanup lock.
> 
> Yes, and your proposal cannot fix that.  Read "The Deletion Algorithm"
> in nbtree/README, particularly the second paragraph.

Yes, understood. Please read the algorithm again. It does guarantee that
each block in the index has been checked to see if nobody is pinning it,
it just avoids performing I/O to prove that.

-- 
 Simon Riggs           www.2ndQuadrant.com
 PostgreSQL Training, Services and Support




view thread (53+ messages)  latest in thread

Message-ID: <1225217237.3971.225.camel@ebony.2ndQuadrant>
Permalink:  ../1225217237.3971.225.camel@ebony.2ndQuadrant/
Also on:    postgresql.org/message-id/1225217237.3971.225.camel@ebony.2ndQuadrant

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-hackers@postgresql.org
  Cc: simon@2ndQuadrant.com, tgl@sss.pgh.pa.us, heikki.linnakangas@enterprisedb.com
  Subject: Re: Visibility map, partial vacuums
  In-Reply-To: <1225217237.3971.225.camel@ebony.2ndQuadrant>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox