Re: Recovering Data from a crashed database

From: Craig Ringer <craig(at)postnewspapers(dot)com(dot)au>
To: Eric Langheinrich <elanghe(at)gmail(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Recovering Data from a crashed database
Date: 2010-04-29 23:39:09
Message-ID: 4BDA189D.1020800@postnewspapers.com.au
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On 30/04/2010 5:29 AM, Eric Langheinrich wrote:
>
> I'm looking for options to recover data from a crashed postgres database
> server. We recently had a solid state storage device blow up taking the
> database server with it.
> The database is version 8.3, the pg_clog, pg_xlog and subdirectories of
> pg_tblspc were wiped out with the crashed storage device. We do have the
> files under /data/base.
> pgfsck looked like the right tool for the job, but seems to be outdated
> and lacking support for 8.3

Whatever you do, and before you do anything else, take a full copy of
everything you still have and put it on storage you then ensure is
read-only. This is important. Any recovery attempt you make may make
things worse, and change the situation from "recoverable" to "completely
hosed".

Once you have a full snapshot, you can supply that to anyone you choose
to help with recovery.

I strongly suggest making sure the original pg data directory is
read-only too. If you're going to do your own recovery attempts, copy
the data to a spare machine and try it there, simply to make sure you've
got everything isolated and there's no chance you're going to stomp on
the original copy.

--
Craig Ringer

In response to

Browse pgsql-general by date

  From Date Subject
Next Message DM 2010-04-29 23:57:02 Re: PostgreSQL Performance issue
Previous Message Thomas Kellerer 2010-04-29 22:08:52 Re: sql help, reusing a column