Thread: BUG #4431: cannot pg_restore from pg_dump --format=c

BUG #4431: cannot pg_restore from pg_dump --format=c

From
"Kieran McCusker"
Date:
The following bug has been logged online:

Bug reference:      4431
Logged by:          Kieran McCusker
Email address:      kieran.mccusker@kwest.info
PostgreSQL version: 8.3.3
Operating system:   Linux (fc9)
Description:        cannot pg_restore from pg_dump --format=c
Details:

Hi

I'm trying to copy a database between two servers (both fc9).

If I do the following:-

pg_dump --format=c --username=portal --file=test.dump Portal

Create the database using:-

createdb -E utf8 --owner=portal --template postgres Portal

then:

pg_restore --dbname=Portal test.dump

The database schema is partially restored and no data added.

If I do the same thing using pg_dump --format=p and loading it using psql
it
works fine. The database was originally created under fc7 (sorry can't
remember the postgresql version) Its a bit worrying as it means none of the
previous nightly
backups are usable.

I can provide the dump if needed (its 230Mb compressed 1.8Gib uncompressed)

Many thanks

Kieran

Re: BUG #4431: cannot pg_restore from pg_dump --format=c

From
Tom Lane
Date:
"Kieran McCusker" <kieran.mccusker@kwest.info> writes:
> The following bug has been logged online:

> Bug reference:      4431
> Logged by:          Kieran McCusker
> Email address:      kieran.mccusker@kwest.info
> PostgreSQL version: 8.3.3
> Operating system:   Linux (fc9)
> Description:        cannot pg_restore from pg_dump --format=c
> Details:

> Hi

> I'm trying to copy a database between two servers (both fc9).

> If I do the following:-

> pg_dump --format=c --username=portal --file=test.dump Portal

> Create the database using:-

> createdb -E utf8 --owner=portal --template postgres Portal

> then:

> pg_restore --dbname=Portal test.dump

> The database schema is partially restored and no data added.

This report is completely laxking in any detail that might allow anyone
to help you.  What do you mean by "partially restored" --- what gets
restored and what doesn't?  What error messages do you get?  (Look in
the postmaster log as well as what comes out of pg_restore.)

            regards, tom lane