From: | Vittorio De Martino <vdemart1(at)tin(dot)it> |
---|---|
To: | pgsql-general(at)postgresql(dot)org |
Subject: | Re: cron & backup |
Date: | 2005-01-19 13:20:52 |
Message-ID: | 200501191320.52425.vdemart1@tin.it |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
Alle 14:38, martedì 18 gennaio 2005, Lonni J Friedman ha scritto:
> On Tue, 18 Jan 2005 11:12:34 +0100, v(dot)demartino2(at)virgilio(dot)it
>
> <v(dot)demartino2(at)virgilio(dot)it> wrote:
> > At office we have a Win2k LAN to which my freebsd postgresql server box
> > is connected via Samba. On this box I have a script, called 'crono',
> > which is dealt by /usr/bin/cron every working day's night at 1 am. As
> > you can see below this crono script vacuums all the DBs and dumps mydb to
> > a samba share.
> >
> > ##crono file
> > vacuumdb -a -U victor
> > pg_dump --create --format=c -O -Uvictor --file=/root/my_dump/mydb.sql.gz
> > mydb
> > ##
> >
> > Now if I execute the script by hand as root it all works smoothly but
> > cron fails frequently to start or complete the execution of the script
> > even though in the cron log I see that it starts it regularly as root at
> > 1 am.
> >
> > The fact is that I don't have any other clue on what is going wrong
> > because of the poor log.
> >
> > What logs shoiuld I enable in the postgresql.conf configuration file to
> > trace what's going on with the vacuumdb and pg_dump commands?
>
> Normally cronjob output is sent to the email address of its owner. Is
> root receiving any email output from this cronjob? Also, you should
> add the -z and -f switches to vacuumdb.
>
> If I had to guess on your probem above, i'd say it could be a $PATH
> issue, since you're not specifying the path for vacuumdb.
Lonni, you were right! The only problem was the absence of the directories of
the
command vacuumdb and pg_dump. I added the Iusr/local/bin/ prefic to both and
now it all works smoothly.
Thanks
Vittorio
From | Date | Subject | |
---|---|---|---|
Next Message | Devrim GUNDUZ | 2005-01-19 13:33:55 | (S)RPMs for PostgreSQL 8.0.0 are ready. |
Previous Message | Marc G. Fournier | 2005-01-19 13:02:46 | PostgreSQL 8.0.0 Released |