From: Craig Ringer <ringerc@ringerc.id.au>
To: Kevin Grittner <Kevin.Grittner@wicourts.gov>
Cc: pgsql-admin@postgresql.org, jkells <jtkells@verizon.net>
Subject: Re: bad block problem
Date: Thu, 08 Dec 2011 09:05:53 +0800
Message-ID: <4EE00D71.6090705@ringerc.id.au> (raw)
In-Reply-To: <4EDFA52F0200002500043A8A@gw.wicourts.gov>
References: <1OQDq.131420$034.90105@en-nntp-06.dc1.easynews.com>
<4EDFA52F0200002500043A8A@gw.wicourts.gov>
On 12/08/2011 07:41 AM, Kevin Grittner wrote:
> That sounds like your storage system is failing, quite independently
> from PostgreSQL. Copy the entire data directory tree to some other
> medium immediately, and preserve this copy. If you hit bad blocks,
> retry if possible.
If you find files you can't copy in their entirety, try using dd_rescue
to copy it with a hole for the bad block. dd_rescue is an _incredibly_
useful tool for this, as it'll do bad-block-tolerant copies quickly and
efficiently.
Once you have a complete copy of your datadir, stop working on the
faulty machine. Make your first copy read-only. Duplicate the copy and
work on the duplicate when trying to restore. I'd start with enabling
zero_damaged_pages to see if you can get a dump that way.
Do **NOT** enable zero_damaged_pages on the original. Do it on the
duplicate of the copied data.
--
Craig Ringer
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 using the --to and --cc options:
reply via email
To: pgsql-admin@postgresql.org
Cc: ringerc@ringerc.id.au, Kevin.Grittner@wicourts.gov, jtkells@verizon.net
Subject: Re: bad block problem
In-Reply-To: <4EE00D71.6090705@ringerc.id.au>
* 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