Re: Problem with pg_dump - Mailing list pgsql-general

From Alan Hodgson
Subject Re: Problem with pg_dump
Date
Msg-id 200611100857.30143@hal.medialogik.com
Whole thread Raw
In response to Re: Problem with pg_dump  ("Alex Turner" <armtuk@gmail.com>)
List pgsql-general
On Friday 10 November 2006 08:37, "Alex Turner" <armtuk@gmail.com> wrote:
> Sure thing, I hope it's as simple as user error!
>
> #!/bin/sh
> export DATE=`date +%Y%m%d`
>
> /usr/local/pgsql/bin/pg_dump -Upostgres -hlocalhost trend >
> /backup/trend.dump.$DATE
>
> Thats pretty much it repeated for each database.  I just upgraded to
> 8.1.5to see if that would fix the problem, but it didn't
>

If you're going to backup each database separately, you also need to run a
pg_dumpall -g to get global objects (roles, etc.), and restore that first.

--
They laughed at Columbus, they laughed at Fulton, they laughed at the
Wright brothers.  But they also laughed at Bozo the Clown." -- Carl Sagan


pgsql-general by date:

Previous
From: Andreas Kretschmer
Date:
Subject: Re: Problem with pg_dump
Next
From: "Alex Turner"
Date:
Subject: Re: Problem with pg_dump