Re: pg_dump 2 gig file size limit on ext3 - Mailing list pgsql-general

From Chris Gamache
Subject Re: pg_dump 2 gig file size limit on ext3
Date
Msg-id 20021206181020.59607.qmail@web13804.mail.yahoo.com
Whole thread Raw
In response to Re: pg_dump 2 gig file size limit on ext3  ("Shridhar Daithankar" <shridhar_daithankar@persistent.co.in>)
List pgsql-general
An even better idea would be to

postgres@db:~# pg_dump db | /usr/bin/split -b 1024m - yourprefix_
That would split your dump into 1GB pieces. Easy to manage.

To get them back in

postgres@db:~# cat yourprefix_aa yourprefix_ab yourprefix_ac | psql -f -

This might even work... (Syntax might be a bit mangled, tho)

postgres@db:~# pg_dump db | /usr/bin/split -b 1024m - yourprefix_ | gzip
postgres@db:~# zcat yourprefix_aa.gz yourprefix_ab.gz yourprefix_ac.gz | psql
-f -

HTH

CG
--- Shridhar Daithankar <shridhar_daithankar@persistent.co.in> wrote:
> On 6 Dec 2002 at 8:47, Tommi Maekitalo wrote:
> > how do you use pg_dump? Versions < 7.3 might not have large file support.
> But
> > you can use 'pg_dump db >dump.out'. pg_dump writes to stdout and do not
> have
> > to deal with the file itself. This is done by your shell. If your shell
> have
> > trouble you should change your shell or use split.
>
> And as pointed out in pg_dump documentation, zipping the dump on the fly is
> another possibility if you have CPU power..
>
> Bye
>  Shridhar
>
> --
> critic, n.:    A person who boasts himself hard to please because nobody tries
> to
> please him.        -- Ambrose Bierce, "The Devil's Dictionary"
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 5: Have you checked our extensive FAQ?
>
> http://www.postgresql.org/users-lounge/docs/faq.html


__________________________________________________
Do you Yahoo!?
Yahoo! Mail Plus - Powerful. Affordable. Sign up now.
http://mailplus.yahoo.com

pgsql-general by date:

Previous
From: Bruce Momjian
Date:
Subject: Re: [7.3] can't connect with SSL
Next
From: Matthew Gabeler-Lee
Date:
Subject: Another planner bug with subqueries