Re: Postgres Backup Questions - Mailing list pgsql-admin

From Scott Marlowe
Subject Re: Postgres Backup Questions
Date
Msg-id 1149179444.25526.139.camel@state.g2switchworks.com
Whole thread Raw
In response to Postgres Backup Questions  ("John R. Allgood" <john@turbocorp.com>)
Responses Re: Postgres Backup Questions  ("John R. Allgood" <john@turbocorp.com>)
List pgsql-admin
On Thu, 2006-06-01 at 10:15, John R. Allgood wrote:
> Hello
>
>     I have a question regarding backups on Postgresql 7.4.7-2. We are
> currently using a Progress database and will be moving over to Postgres
> this month. In Progress there is a way to verify your backups does
> Postgres have anything similiar or is there other ways to accompplish
> this. I am currently writing backup and other utility scripts and would
> like to incorporate this into my program.

I wrapped my backup in a bash script, and that seems to catch errors.
something like:

if !(
   /data01/pg/bin/pg_dump dbname > dbname.sql
    );
then
    cat "backup failed"|mail -s "backup failed" yourname@yourdomain.com;
fi

To test this, I corrupted a table in a test database to force a hard
failure, and it sent an email.  Don't know if it's a comprehensive test,
but it seems to work for us.

pgsql-admin by date:

Previous
From: "John R. Allgood"
Date:
Subject: Postgres Backup Questions
Next
From: "John R. Allgood"
Date:
Subject: Re: Postgres Backup Questions