Re: Status of 8.3 patches - Mailing list pgsql-hackers

From ITAGAKI Takahiro
Subject Re: Status of 8.3 patches
Date
Msg-id 20070821140342.6D20.ITAGAKI.TAKAHIRO@oss.ntt.co.jp
Whole thread Raw
In response to Re: Status of 8.3 patches  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
Tom Lane <tgl@sss.pgh.pa.us> wrote:

> >> o  Error correction for n_dead_tuples

> Also, I'm still quite unhappy that the patch converts the tracking of
> n_dead_tuples into a dead-reckoning system in which incremental changes
> are continually applied without any feedback that'd prevent the value
> from diverging arbitrarily far from reality.  Murphy's law says that
> the value *will* diverge, if you don't have any negative feedback
> in the loop to force it to track reality.

There is *no feedback loop* in the patch. It will clear the stats at the
beginning of vacuum, and leave n_dead_tuples collected during the vacuum.
Even if some errors are left after the vacuum, they will be cleared at
the next vacuum. Errors should not be accumulated through repeated vacuums.


> There may be something to be done here, but there's not any evidence
> at hand that CVS HEAD actually suffers from a problem in tracking
> n_dead_tuples, and even if it does I do not think that this particular
> patch is a good fix.

The problem is in the cost-based delayed vacuum. We turned cost-delay on
as default and will encourage to use autovacuum at 8.3. Dead tuple ratio
is not predictable from autovacuum_vacuum_scale_factor in the current
behavior; It might make DBA feel unhappy.

Regards,
---
ITAGAKI Takahiro
NTT Open Source Software Center




pgsql-hackers by date:

Previous
From: Greg Smith
Date:
Subject: Re: Status of 8.3 patches
Next
From: Greg Smith
Date:
Subject: Re: 8.3 beta testing suggestions welcome