Skip site navigation (1) Skip section navigation (2)

Re: [GENERAL] How to salvage a corrupted DB?

From: Michael Simms <grim(at)argh(dot)demon(dot)co(dot)uk>
To: mdalphin(at)amgen(dot)com (Mark Dalphin)
Cc: pgsql-general(at)postgreSQL(dot)org
Subject: Re: [GENERAL] How to salvage a corrupted DB?
Date: 1999-09-24 18:56:46
Message-ID: 199909241856.TAA04505@argh.demon.co.uk (view raw or flat)
Thread:
Lists: pgsql-general
> Hi,
> 
> I have an important database which I have been unable to backup/dump for "a long
> while". I am looking for a method to "fix" the problem.  As a last resort, I
> guess I could dump the DB table by table using "\copy", although I haven't tried
> yet. And I worry that the corrupted system tables may be accessed during a
> "\copy" so I may still be stuck.

<snip>

> Okay, what tables are present?
> 
> > htg=> \d
> > pqReadData() -- backend closed the channel unexpectedly.
> >         This probably means the backend terminated abnormally
> >         before or while processing the request.
> > htg=>
> >
> Well, not quite such a hard crash; I'm still in psql, however, I am not
> connected to any DB an longer.

At the worst, you could, as you say, dump out the tables using copy.
To get the table list, look in the data directory, and you should see
all you need to know what tables are there

						~Michael

In response to

pgsql-general by date

Next:From: Richard RyanDate: 1999-09-24 21:50:54
Subject: Any books available commercially?
Previous:From: Mark DalphinDate: 1999-09-24 18:11:32
Subject: How to salvage a corrupted DB?

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group