Re: [GENERAL] Encoding problem using pg_dumpall

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sat, Jan 31, 2009 at 12:23 AM, Michael Monnerie
<michael.monnerie@xxxxxxxxxxxxxxxxxxx> wrote:
> On Freitag 30 Januar 2009 Tom Lane wrote:
>> The -Fc (and -Ft) formats are only designed to hold the contents of a
>> single database; and pg_restore only knows how to restore into a
>> single database.
>>
>> If you feel like fixing that, step right up.
>
> Sorry, didn't want to step on toes here. I know that sometimes if you
> perfectly know a system you get blind over alternatives, and wanted to
> throw in an idea.
>
> The format of pg_dumpall could be a tar of single pg_dumps as well,
> making pg_dumpall just call pg_dump for each db, putting that output
> into the tar output from pg_dumpall. But again, just an idea, I don't
> mind really. I'm just a sysadmin who wants things as easy as possible.
> Maybe fixing pg_dumpall to include that -E is easier.
>
You should be able to knock up a simple script in bash, perl or python
to do what you want.

Sort of like:

Use 'psql' to get a list of the databases
Sanitize the list.
Loop through the list doing backup.
At the end zip them all.

With a little bit of trickery you should be able to zip them as you go.

With regards being too close to the system, while this is true, it
also possible to be distant from the system's entrails and not don't
realize the implications and difficulties of your brilliant idea for
enhancement!

Cheers,

Cliff

-- 
Sent via pgsql-admin mailing list (pgsql-admin@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin

[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux