pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Cliff Pratt <enkiduonthenet@gmail.com>
To: pgsql-admin@postgresql.org
Subject: Re: [GENERAL] Encoding problem using pg_dumpall
Date: Sun, 1 Feb 2009 12:47:53 +1300
Message-ID: <9adabaf40901311547r1444e0c4m4797da5b30671d63@mail.gmail.com> (raw)
In-Reply-To: <200901301223.49703@zmi.at>
References: <75E4C42D37E6A74E9FB57C2E9F1300D60107073E@tiger.nexperience.com>
	<200901292014.29195@zmi.at>
	<14708.1233277601@sss.pgh.pa.us>
	<200901301223.49703@zmi.at>

On Sat, Jan 31, 2009 at 12:23 AM, Michael Monnerie
<michael.monnerie@is.it-management.at> 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



view thread (10+ messages)  latest in thread

Message-ID: <9adabaf40901311547r1444e0c4m4797da5b30671d63@mail.gmail.com>
Permalink:  ../9adabaf40901311547r1444e0c4m4797da5b30671d63@mail.gmail.com/
Also on:    postgresql.org/message-id/9adabaf40901311547r1444e0c4m4797da5b30671d63@mail.gmail.com

 · 

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: enkiduonthenet@gmail.com
  Subject: Re: [GENERAL] Encoding problem using pg_dumpall
  In-Reply-To: <9adabaf40901311547r1444e0c4m4797da5b30671d63@mail.gmail.com>

* 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