pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: lists <lists@insyde.com.br>
To: pgsql-admin@postgresql.org
Subject: Re: pg_restore problem
Date: Mon, 31 Mar 2003 11:19:02 -0300
Message-ID: <014401c2f790$7c244be0$fafaabc8@insyde> (raw)
References: <003201c2f526$8e88fd60$8efaabc8@insyde>
	<1049118197.13798.1712.camel@camel>

> Are you sure your restoring to an empty database? If you try to restore
> your dump into the database you dumped it from (without first
> drop/create) it will take forever as you'll have all kinds of data
> collisions (imagine every insert into a table erroring out due to
> duplicate primary key).

Yes, I'm sure it is an empty database. I didn't mention in the e-mail,
but the complete script I did is:

$pg_dump  -s DB1 > DB1.sql

$pg_dump -a -b -Fc -f  DB1.dump -o -v DB1

$dropdb DB2

$createdb DB2

$psql DB2 <DB1.sql

$pg_restore -a -d DB2 -Fc -o -v DB1.dump

So it's a brand new DB I'm restoring to.

> As for the -Ft vs. -Fc size question, the tar format is not a compressed
> format, while the "c"ustom format is.
Thanks.

Ricardo.




view thread (17+ messages)  latest in thread

Message-ID: <014401c2f790$7c244be0$fafaabc8@insyde>
Permalink:  ../014401c2f790$7c244be0$fafaabc8@insyde/
Also on:    postgresql.org/message-id/014401c2f790$7c244be0$fafaabc8@insyde

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-admin@postgresql.org
  Cc: lists@insyde.com.br
  Subject: Re: pg_restore problem
  In-Reply-To: <014401c2f790$7c244be0$fafaabc8@insyde>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox