Re: [GENERAL] [ADMIN] backup of postgres scheduled with cron

2007-11-22 Thread Martin Gainty
Good Morning AndrewI noticed the Vixie cron responds to SIGHUP signalsDo you have any suggestions or tutorials on how Postgres would feed these event signals to Vixie cron? Thanks/Martin __Disclaimer and confidentiality noteEverything in this e-mail a

Re: [GENERAL] [ADMIN] backup of postgres scheduled with cron

2007-11-22 Thread Andrew Sullivan
On Thu, Nov 22, 2007 at 09:14:13AM -0500, Martin Gainty wrote: > > Good Morning AndrewI noticed the Vixie cron responds to SIGHUP signalsDo > you have any suggestions or tutorials on how Postgres would feed these > event signals to Vixie cron? Why would Postgres have to tell crond to restart? A

Re: [ADMIN] backup of postgres scheduled with cron

2007-11-22 Thread Andrew Sullivan
On Thu, Nov 22, 2007 at 02:59:33PM +0100, Marco Bizzarri wrote: > Andrew, can you confirm the previous statement? I'm checking on a Debian > Linux, > at it seems to be a Vixie Cron, and that feature is described in the man > page... If the feature's in your man page, then it works on your system

Re: [ADMIN] backup of postgres scheduled with cron

2007-11-22 Thread Marco Bizzarri
On Nov 22, 2007 2:53 PM, Andrew Sullivan <[EMAIL PROTECTED]> wrote: > On Thu, Nov 22, 2007 at 02:28:08PM +0100, Marco Bizzarri wrote: > > > > why don't you add a "MAILTO=" at the start of your > > crontab file, so that you can receive a report of the problem? > > Note: check that your cron accepts

Re: [ADMIN] backup of postgres scheduled with cron

2007-11-22 Thread Andrew Sullivan
On Thu, Nov 22, 2007 at 02:28:08PM +0100, Marco Bizzarri wrote: > > why don't you add a "MAILTO=" at the start of your > crontab file, so that you can receive a report of the problem? Note: check that your cron accepts such an addition. Many systems now use Vixie's cron, which does accept that,

Re: [ADMIN] backup of postgres scheduled with cron

2007-11-22 Thread Marco Bizzarri
On Nov 22, 2007 2:46 PM, Sorin N. Ciolofan <[EMAIL PROTECTED]> wrote: > Hi Marco! > > Thank you for the advice. > > I got: > > /home/swkm/services/test/backup.sh: line 4: pg_dump: command not found > updating: mydb_dump_22-11-07.out (stored 0%) > > which seems strange > > Try putting the full path

Re: [ADMIN] backup of postgres scheduled with cron

2007-11-22 Thread Sorin N. Ciolofan
: Thursday, November 22, 2007 3:28 PM To: Sorin N. Ciolofan Cc: [email protected]; [EMAIL PROTECTED] Subject: Re: [ADMIN] backup of postgres scheduled with cron On Nov 22, 2007 2:19 PM, Sorin N. Ciolofan <[EMAIL PROTECTED]> wrote: > Hello all! > > I've a small bash

Re: [ADMIN] backup of postgres scheduled with cron

2007-11-22 Thread Marco Bizzarri
On Nov 22, 2007 2:19 PM, Sorin N. Ciolofan <[EMAIL PROTECTED]> wrote: > Hello all! > > I've a small bash script backup.sh for creating dumps on my Postgre db: > > #!/bin/bash > time=`date '+%d'-'%m'-'%y'` > cd /home/swkm/services/test > pg_dump mydb > mydb_dump_$time.o

[ADMIN] backup of postgres scheduled with cron

2007-11-22 Thread Sorin N. Ciolofan
Hello all! I've a small bash script backup.sh for creating dumps on my Postgre db: #!/bin/bash time=`date '+%d'-'%m'-'%y'` cd /home/swkm/services/test pg_dump mydb > mydb_dump_$time.out I've edited crontab and added a line: 00 4 * * * swkm /home/swkm/services/test

Re: [ADMIN] Backup of postgres

1998-08-21 Thread Przemyslaw Bak
On Wed, 19 Aug 1998, Marc Howard Zuckman wrote: > > On Wed, 19 Aug 1998, Przemyslaw Bak wrote: > > > Hi all, > > > > I have following script to backup database: > > - cut -- > > #!/bin/sh > > > > PSQL=/usr/local/pgsql/bin/psql > > DUMP=/usr/local/pgsql/bin/pg_dump > > PREFIX=`d

Re: [ADMIN] Backup of postgres

1998-08-19 Thread Marc Howard Zuckman
On Wed, 19 Aug 1998, Przemyslaw Bak wrote: > Hi all, > > I have following script to backup database: > - cut -- > #!/bin/sh > > PSQL=/usr/local/pgsql/bin/psql > DUMP=/usr/local/pgsql/bin/pg_dump > PREFIX=`date +%j` > BACKUP_DIR=/usr/local/pgsql/data/base/.BACKUP > > Databases=

[ADMIN] Backup of postgres

1998-08-19 Thread Przemyslaw Bak
Hi all, I have following script to backup database: - cut -- #!/bin/sh PSQL=/usr/local/pgsql/bin/psql DUMP=/usr/local/pgsql/bin/pg_dump PREFIX=`date +%j` BACKUP_DIR=/usr/local/pgsql/data/base/.BACKUP Databases=`$PSQL -tq -d template1 -c "select datname from pg_database"` renice