Re: zero_damaged_pages doesn't work

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: David Boreham <david_list(at)boreham(dot)org>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: zero_damaged_pages doesn't work
Date: 2010-09-27 22:53:42
Message-ID: 6752.1285628022@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

David Boreham <david_list(at)boreham(dot)org> writes:
> On 9/27/2010 4:40 PM, Jeff Davis wrote:
>> 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.

The reason it tells you that data will be destroyed is that that could
very well happen. If the system decides to put new data into what will
appear to it to be an empty page, then the damaged data on disk will be
overwritten, and then there's no hope of recovering anything.

Like Jeff said, this is not a recovery tool. It's certainly not meant
to be something that you keep turned on for any length of time, and so
the possibility of repeat messages is really not a design consideration
at all.

regards, tom lane

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message David Boreham 2010-09-27 22:58:56 Re: zero_damaged_pages doesn't work
Previous Message Satoshi Nagayasu 2010-09-27 22:51:35 Re: ECPG - Some errno definitions don't match to the manual