Re: zero_damaged_pages doesn't work - Mailing list pgsql-general

From David Boreham
Subject Re: zero_damaged_pages doesn't work
Date
Msg-id 4CA11E8C.7040104@boreham.org
Whole thread Raw
In response to Re: zero_damaged_pages doesn't work  (Jeff Davis <pgsql@j-davis.com>)
Responses Re: zero_damaged_pages doesn't work  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-general
  On 9/27/2010 4:40 PM, Jeff Davis wrote:
> It does zero the page in the buffer, but I don't think it marks it as
> dirty. So, it never really makes it to disk as all-zeros.

Ah ha ! This is certainly consistent with the observed behavior.

> zero_damaged_pages is not meant as a recovery tool. It's meant to allow
> you to pg_dump whatever data is not damaged, so that you can restore
> into a fresh location.

It'd be useful for future generations if this were included in the doc.

The latest version :
http://www.postgresql.org/docs/9.0/static/runtime-config-developer.html
still talks about destroying data (which at least to me implies a
persistent change
to the on-disk bits) and fails to mention that the zeroing only occurs
in the
page pool sans write-back.

If it helps, I'd be happy to contribute some time to fix up the docs,
but imho a simple
copy/paste of your text above would be sufficient.



pgsql-general by date:

Previous
From: "Larry Leszczynski"
Date:
Subject: PostgreSQL 9 Mac OS X one-click install - PL/perl broken
Next
From: Tom Lane
Date:
Subject: Re: zero_damaged_pages doesn't work