From: | Simon Riggs <simon(at)2ndquadrant(dot)com> |
---|---|
To: | Alvaro Herrera <alvherre(at)commandprompt(dot)com> |
Cc: | Decibel! <decibel(at)decibel(dot)org>, Zeugswetter Andreas ADI SD <Andreas(dot)Zeugswetter(at)s-itsolutions(dot)at>, Magnus Hagander <magnus(at)hagander(dot)net>, pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: pg_dump additional options for performance |
Date: | 2008-02-11 10:13:15 |
Message-ID: | 1202724795.4247.179.camel@ebony.site |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Fri, 2008-02-08 at 17:01 -0300, Alvaro Herrera wrote:
> Decibel! wrote:
>
> > For that matter, it'd be better if you could just get all 3 files (pre,
> > data, post) in one shot with one transaction; that would guarantee you a
> > clean dump.
>
> +1.
OK, that seems possible.
What do you think the syntax should be for that?
If you specify --data-only you get 1 file
If you specify --schema-only you get either 1 or 2 files
and if you don't specify either you get either 1 or 3 files
How do we name the files?
--pre-schema-file
--data-file
--post-schema-file
If any of the above 3 files are named then --file is treated as an
error.
That allows you to do this:
* dump all 3 files in one go
pg_dump --pre-schema-file=pre_schema.dmp --data-file=data.dmp
--post-schema-file=post_schema.dmp
* dump 2 files for schema
pg_dump --pre-schema-file=pre_schema.dmp
--post-schema-file=post_schema.dmp --schema-only
--
Simon Riggs
2ndQuadrant http://www.2ndQuadrant.com
From | Date | Subject | |
---|---|---|---|
Next Message | Alvaro Herrera | 2008-02-11 15:15:17 | Re: pg_dump additional options for performance |
Previous Message | Stefan Kaltenbrunner | 2008-02-10 19:49:38 | Re: Patch review |