Re: Create Linux Script for PostgreSQL database backup - Mailing list pgsql-admin

From Kaolin Fire
Subject Re: Create Linux Script for PostgreSQL database backup
Date
Msg-id 4136C42B.50303@tentacle.net
Whole thread Raw
In response to Re: Create Linux Script for PostgreSQL database backup  (tim hall <tech@glastonburymusic.org.uk>)
Responses Re: Create Linux Script for PostgreSQL database backup  (Geoffrey <esoteric@3times25.net>)
Re: Create Linux Script for PostgreSQL database backup  (Sanjay Arora <skpobox@gawab.com>)
List pgsql-admin
For that matter:

echo "1   3   *   *   *   postgres   /usr/local/bin/pg_dumpall >
~/backup.sql" >> /etc/crontab

note to remember the two >>'s so you don't obliterate your crontab like
I just did.

:ulp:

-kaolin

tim hall wrote:

>Lawrence C,
>On Wednesday 01 September 2004 14:20, you went:
>
>
>>Anyone good in writing Linux scripting for backup
>>PostgreSQL. I just required a simple scripts only.
>>
>>Normally we do the manual ways as following:
>>
>>In root
>>
>>root# su - postgres
>>bash# pgdumpall >  backup.sql
>>bash# exit
>>root#
>>
>>I'm planning to write script.sh for cronjob but not
>>too sure about it. Can anyone contribute the scripts
>>for me?
>>
>>
>
>Er ...
>
>#! /usr/bin/bash
>pgdumpall >  backup.sql
>
>I'm being cheeky, but surely if you set that up as a cronjob for user
>'postgres' that would do it? Are your needs more complex than this?
>
>cheers
>
>tim hall
>
>---------------------------(end of broadcast)---------------------------
>TIP 8: explain analyze is your friend
>
>
>


pgsql-admin by date:

Previous
From: tim hall
Date:
Subject: Re: Create Linux Script for PostgreSQL database backup
Next
From: Peter Eisentraut
Date:
Subject: Re: Help understanding locale