Re: Recover an existing database - Mailing list pgsql-general

From Tom Lane
Subject Re: Recover an existing database
Date
Msg-id 9655.1011384063@sss.pgh.pa.us
Whole thread Raw
In response to Recover an existing database  ("Peter Bayley" <peterb@homer.com.au>)
List pgsql-general
"Peter Bayley" <peterb@homer.com.au> writes:
> I had a hard disk crash recently and had to reinstall  Linux (RedHat 7.2) a=
> nd consequently postgres (7.1.3) on the new root disk.  My large database (=
> also 7.1.3) was mounted on another volume and I had created it using the "C=
> REATE DATABASE WITH LOCATION=3D" syntax.
> =20
> My question is:  How can I change the new postgres install to recognise my =
> existing database?

You can't, if I'm correctly interpreting this scenario to mean that you
lost pg_log.  Your transaction history, transaction numbers, and OIDs
are not in sync with the data files.  While the OID counter isn't all
that critical, the transaction history definitely is.  Sorry.

            regards, tom lane

pgsql-general by date:

Previous
From: steve@zeropps.uklinux.net (Steve)
Date:
Subject: Re: Having problem with initdb on my Solaris 8 box
Next
From: Jason Earl
Date:
Subject: Re: sharing data accross several databases