I'm doing some backup action for my database using crontab. Unfortunately the following entry doesn't work and I can't figure out the problem: ----------------------------- /etc/crontab --------------------------- 05 22 * * 1-5 postgres /usr/bin/pg_dumpall -D > /disks/postgres/db.pg_dumpall ----------------------------------------------------------------------
The message I get is: ---------------------------- stderr ---------------------------------- connected to template1... /usr/bin/pg_dumpall: 0: Bad file descriptor ---------------------------------------------------------------------- The outputfile looks like: ----------------------- the output file ------------------------------ -- -- pg_dumpall (7.2) -D -- \connect template1 DELETE FROM pg_shadow WHERE usesysid <> (SELECT datdba FROM pg_database WHERE datname = 'template0'); CREATE USER "werner" WITH SYSID 100 CREATEDB CREATEUSER; CREATE USER "martin" WITH SYSID 101 NOCREATEDB NOCREATEUSER; CREATE USER "juergen" WITH SYSID 102 CREATEDB NOCREATEUSER; CREATE USER "www" WITH SYSID 103 NOCREATEDB NOCREATEUSER; CREATE USER "procad" WITH SYSID 99 NOCREATEDB NOCREATEUSER; DELETE FROM pg_group; ---------------------------------------------------------------------- That's all. No databases dumped. Calling pg_dumpall manually works fine. Whe is the problem? Any hints? - Werner - ---------------------------(end of broadcast)--------------------------- TIP 1: subscribe and unsubscribe commands go to [EMAIL PROTECTED]