Re: HOT patch, missing things

From: "Simon Riggs" <simon(at)2ndquadrant(dot)com>
To: "Pavan Deolasee" <pavan(dot)deolasee(at)gmail(dot)com>
Cc: "Heikki Linnakangas" <heikki(at)enterprisedb(dot)com>, "Pavan Deolasee" <pavan(at)enterprisedb(dot)com>, "PostgreSQL-development" <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: HOT patch, missing things
Date: 2007-08-09 07:24:37
Message-ID: 1186644277.4208.60.camel@ebony.site
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Thu, 2007-08-09 at 12:39 +0530, Pavan Deolasee wrote:

> No, pruning removes all dead tuples, irrespective of whether they are
> HOT or COLD updated and whether they are heap-only or not. It
> handles line pointer redirection and marks
> all dead tuples as ~LP_USED. Defragging just repairs the fragmentation
> by rearranging LP_USED tuples.
>
>
> It's easily possible that 100% of the cold updates and deletes
> are
> removed by defragging because of HOT updates. It would be
> pointless to
> trigger a VACUUM when it might find nothing to clear up. Its
> also
> possible that the deletes are at one end of the table and the
> updates at
> the other. So we really need to keep track of the effects of
> defragging
> dead cold updates and deletes, so they can be subtracted from
> the cold
> update + deletes.

Whether I got the exact details of frugging & depruning correct or not:
if a tuple version is removed, then VACUUM doesn't need to remove it
later, so any non-VACUUM removal of rows must defer a VACUUM.

--
Simon Riggs
EnterpriseDB http://www.enterprisedb.com

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Simon Riggs 2007-08-09 07:32:22 Re: Unexpected VACUUM FULL failure
Previous Message Simon Riggs 2007-08-09 07:16:35 Re: GUC for default heap fillfactor