pg.ddx.io pgsql-sql@postgresql.org mailing list archive
help / color / mirror / Atom feedrestoring a dump
4+ messages / 3 participants
[nested] [flat]
* restoring a dump
@ 2001-06-28 18:13 Phuong Ma <pma@commandprompt.com>
0 siblings, 1 reply; 4+ messages in thread
From: Phuong Ma @ 2001-06-28 18:13 UTC (permalink / raw)
To: pgsql-sql
Hello,
I have been trying to restore my dump and it seems like it is not
working. I put the dump in a tar file and when I untarred it, there are
several .dat files, a toc.dat file, and a restore.sql file. I used psql
to restore these files into a database. I first started restoring the
restore.sql file, then the .dat files, and lastly, the toc.dat. When I
did the toc.dat file, I received an error message. These are the
pg_dump -C -D -F t > test.tar
tar -xvf test.tar
psql restore.sql
psql test < 19.dat
psql test < 20.dat .. and so on
psql test < toc.dat
This is the error message:
ERROR: parser: parse error at or near "pgdmp"
CHANGE
ERROR: non-existent group "test"
ERROR: parser: parse error at or near """
ERROR: parser: parse error at or near """
ERROR: parser: parse error at or near """
ERROR: parser: parse error at or near """
ERROR: parser: parse error at or near """
ERROR: parser: parse error at or near """
ERROR: parser: parse error at or near """
ERROR: parser: parse error at or near """
ERROR: parser: parse error at or near """
I also tried using the pg_restore, but I don't know how that would work
on these separate files. Is there another way I can restore the dump?
Maybe an easier way than what I have been using? And do I need to
restore what is in the toc.dat?
Thank you for your help.
^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: restoring a dump
@ 2001-06-28 21:27 Peter Eisentraut <peter_e@gmx.net>
parent: Phuong Ma <pma@commandprompt.com>
0 siblings, 1 reply; 4+ messages in thread
From: Peter Eisentraut @ 2001-06-28 21:27 UTC (permalink / raw)
To: Phuong Ma <pma@commandprompt.com>; +Cc: pgsql-sql
Phuong Ma writes:
> pg_dump -C -D -F t > test.tar
> tar -xvf test.tar
> psql restore.sql
> psql test < 19.dat
> psql test < 20.dat .. and so on
> psql test < toc.dat
I believe you're supposed to use pg_restore on the tar file itself.
--
Peter Eisentraut peter_e@gmx.net http://funkturm.homeip.net/~peter
^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: restoring a dump
@ 2001-06-28 23:32 Phuong Ma <pma@commandprompt.com>
parent: Peter Eisentraut <peter_e@gmx.net>
0 siblings, 1 reply; 4+ messages in thread
From: Phuong Ma @ 2001-06-28 23:32 UTC (permalink / raw)
To: Peter Eisentraut <peter_e@gmx.net>; +Cc: pgsql-sql
Peter Eisentraut wrote:
>
> Phuong Ma writes:
>
> > pg_dump -C -D -F t > test.tar
> > tar -xvf test.tar
> > psql restore.sql
> > psql test < 19.dat
> > psql test < 20.dat .. and so on
> > psql test < toc.dat
>
> I believe you're supposed to use pg_restore on the tar file itself.
>
> --
> Peter Eisentraut peter_e@gmx.net http://funkturm.homeip.net/~peter
I tried using pg_restore, but it did not restore the dump successfully.
Maybe it is the syntax I'm using, but I remember reading that you cannot
use the pg_restore to restore a dump that uses INSERT. Does anyone know
of a way I could undump my db?
^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: restoring a dump
@ 2001-06-29 00:59 Wei Weng <wweng@kencast.com>
parent: Phuong Ma <pma@commandprompt.com>
0 siblings, 0 replies; 4+ messages in thread
From: Wei Weng @ 2001-06-29 00:59 UTC (permalink / raw)
To: Phuong Ma <pma@commandprompt.com>; +Cc: Peter Eisentraut <peter_e@gmx.net>; pgsql-sql
Do not understand your question.
On 28 Jun 2001 16:32:47 -0700, Phuong Ma wrote:
<snip>
> I tried using pg_restore, but it did not restore the dump successfully.
> Maybe it is the syntax I'm using, but I remember reading that you cannot
> use the pg_restore to restore a dump that uses INSERT. Does anyone know
What do you mean by "dump that uses INSERT"?a
> of a way I could undump my db?
>
--
Wei Weng
Network Software Engineer
KenCast Inc.
^ permalink raw reply [nested|flat] 4+ messages in thread
end of thread, other threads:[~2001-06-29 00:59 UTC | newest]
Thread overview: 4+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2001-06-28 18:13 restoring a dump Phuong Ma <pma@commandprompt.com>
2001-06-28 21:27 ` Peter Eisentraut <peter_e@gmx.net>
2001-06-28 23:32 ` Phuong Ma <pma@commandprompt.com>
2001-06-29 00:59 ` Wei Weng <wweng@kencast.com>
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