pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Alvaro Herrera <alvherre@commandprompt.com>
Cc: Hitesh Bhambhani <hitesh.bhambhani@asg.com>
Cc: pgsql-bugs <pgsql-bugs@postgresql.org>
Subject: Re: BUG #5599: Vacuum fails due to index corruption issues
Date: Thu, 05 Aug 2010 13:19:41 -0400
Message-ID: <23590.1281028781@sss.pgh.pa.us> (raw)
In-Reply-To: <1281027356-sup-6865@alvh.no-ip.org>
References: <201008042147.o74LlCge057659@wwwmaster.postgresql.org>
	<1280978913-sup-5475@alvh.no-ip.org>
	<8B7319E089E48047A0B688CE9CF54FD855C3C916@USRES8MAIL.asg.com>
	<1880.1281020817@sss.pgh.pa.us>
	<1281025234-sup-1704@alvh.no-ip.org>
	<16374.1281026184@sss.pgh.pa.us>
	<1281027356-sup-6865@alvh.no-ip.org>

Alvaro Herrera <alvherre@commandprompt.com> writes:
> Excerpts from Tom Lane's message of jue ago 05 12:36:24 -0400 2010:
>> Gone?  Looks like it's still there to me.

> I mean the btree code that does the truncation on vacuum full is
> truncated.  There are other uses for truncation, but it doesn't look to
> that they are as problematic ... or are they?

I think what Hitesh reported is a special case of a generic problem.

> Hmm, I guess truncation of heap on lazy vacuum is still a problem
> precisely because page compaction will be forgotten.

Page compaction is the least of it :-(

Imagine that we have some rows at the end of a table, we delete them,
we vacuum before the next checkpoint.  Vacuum decides it can now
truncate away the last pages, but fails to do so.  The original page
state is still on disk, which means we have lost the fact of the
deletion --- the rows are now effectively live again, though their
index entries are probably gone.

In any case, the removal of VACUUM FULL didn't completely disable
shrinking of btree indexes did it?  I don't recall having removed
that.

			regards, tom lane



view thread (18+ messages)  latest in thread

Message-ID: <23590.1281028781@sss.pgh.pa.us>
Permalink:  ../23590.1281028781@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/23590.1281028781@sss.pgh.pa.us

 · 

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 from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-bugs@postgresql.org
  Cc: tgl@sss.pgh.pa.us, alvherre@commandprompt.com, hitesh.bhambhani@asg.com
  Subject: Re: BUG #5599: Vacuum fails due to index corruption issues
  In-Reply-To: <23590.1281028781@sss.pgh.pa.us>
  References: <201008042147.o74LlCge057659@wwwmaster.postgresql.org> <1280978913-sup-5475@alvh.no-ip.org> <8B7319E089E48047A0B688CE9CF54FD855C3C916@USRES8MAIL.asg.com> <1880.1281020817@sss.pgh.pa.us> <1281025234-sup-1704@alvh.no-ip.org> <16374.1281026184@sss.pgh.pa.us> <1281027356-sup-6865@alvh.no-ip.org> <23590.1281028781@sss.pgh.pa.us>

* 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