Re: Is it possible to recover the schema from the raw files? - Mailing list pgsql-general

From Karsten Hilbert
Subject Re: Is it possible to recover the schema from the raw files?
Date
Msg-id 20160424160148.GK22543@hermes.hilbert.loc
Whole thread Raw
In response to Re: Is it possible to recover the schema from the raw files?  ("Tomas J Stehlik" <tomas@stehlik.co.uk>)
Responses Re: Is it possible to recover the schema from the raw files?
List pgsql-general
On Sun, Apr 24, 2016 at 04:42:21PM +0100, Tomas J Stehlik wrote:

>> If I recall correctly, you stated that the data isn't
>> important in this
>
> Yes, exactly. However, pages in blocks apparently store also the
> representations of the database schemas. And those are also corrupt.

In that case _my_ knowledge also goes only so far as to be
able to fear "no it is not possible".

More knowledgeable people may - given more detailed
information - still be able to suggest approaches to
recover most if not all of the schema.

Like replacing (some of) the pg_* containing raw files with
those from an uncorrupted database (having been suggested
earlier this year) which may work if the corrupted blocks in
pg_* only affect data actually describing _that_ database
rather than establishing relationships not unique to this
database (say, encodings, default operators, ...). If those
can be replaced and there is still corruption in some parts
describing the local schema then it may work to apply
zero_damaged_pages, pg_resetxlog, and similar tools in order
to make some of the schema dumpable.

It may help to look into disabling system indexe as well.

Best regards,
Karsten
--
GPG key ID E4071346 @ eu.pool.sks-keyservers.net
E167 67FD A291 2BEA 73BD  4537 78B9 A9F9 E407 1346


pgsql-general by date:

Previous
From: "Tomas J Stehlik"
Date:
Subject: Re: Is it possible to recover the schema from the raw files?
Next
From: "Tomas J Stehlik"
Date:
Subject: Re: Is it possible to recover the schema from the raw files?