Re: dump from 8.x restore to 7.3.x - Mailing list pgsql-admin

From Edoardo Ceccarelli
Subject Re: dump from 8.x restore to 7.3.x
Date
Msg-id 4575670E.9050509@axa.it
Whole thread Raw
In response to Re: dump from 8.x restore to 7.3.x  (Jim Nasby <decibel@decibel.org>)
List pgsql-admin
>
> On the other hand, dumping a newer version database with an older
> version of *pg_dump* is much more likely to succeed. It's not a
> guarantee, but it should get you pretty close. And as someone else
> mentioned, doing a plain text dump is probably your best bet in this case.

No, that's not an option, I have tried several combinations like using
old pg_dump on a new db but the results are always the same: no way to
restore a newer db on an older pg (my test were only about PG8 - PG7)
The best solution is the one that Adam was suggesting (btw Thank you) in
this same thread, doing a "pg_dump -Fp" on the new db and restoring it
with a
\i FILENAME from the old PG

The only issue about this is that it doesn't treat LO's at all, but it
was enough in my "disaster recovery" scenario.

I started investigating about dumping and restoring LO's and I found a
pretty interesting project under the 7.4 contrib dir, but it seems it's
not maintained any more and I didn't manage to compile it.
Using the lo_export - import function seems doesn't work for "ALL" the
LO's of the database.. maybe it's possible to write a query to do that
but - again - it wasn't so important to save blobs

Thank you again to everybody for your help
Edoardo


pgsql-admin by date:

Previous
From: Adam Radlowski
Date:
Subject: JDBC driver does not accept good md5 passwords
Next
From: Tom Lane
Date:
Subject: Re: dump from 8.x restore to 7.3.x