Received: from localhost.localdomain (postgresql.org [64.49.215.8]) by localhost (Postfix) with ESMTP id 58A37475473 for ; Fri, 21 Jun 2002 02:36:38 -0400 (EDT) Received: from inet2.alc.de (inet2.alc.de [212.117.69.58]) by postgresql.org (Postfix) with ESMTP id 7C13D475469 for ; Fri, 21 Jun 2002 02:36:36 -0400 (EDT) Received: from werner (werner@werner.alc.de [193.28.5.70]) by inet2.alc.de (8.9.3/8.8.7) with ESMTP id IAA19247 for ; Fri, 21 Jun 2002 08:36:36 +0200 Content-Type: text/plain; charset="iso-8859-15" From: Werner Modenbach Organization: ALC Computertechnik GmbH To: pgsql-admin@postgresql.org Subject: pg_dumpall in crontab Date: Fri, 21 Jun 2002 08:35:37 +0200 User-Agent: KMail/1.4.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Message-Id: <200206210835.41137.modenbach@alc.de> X-Archive-Number: 200206/162 X-Sequence-Number: 4596 -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Hi all, I have a stange problem when executing pg_dumpall as a cron job. The crontab entry looks like: 05 22 * * 1-5 postgres /usr/bin/pg_dumpall -D > /disks/postgres/db.pg_dumpall On stderr I get the message connected to template1... /usr/bin/pg_dumpall: 0: Bad file descriptor The createt dumpfile looks like: - -- - -- 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 .... // more users DELETE FROM pg_group; There are no further lines in here. When calling # /disks/postgres/db.pg_dumpall -D > /disks/postgres/db.pg_dumpall' manually as user postgres the dumpfile continues like: - -- - -- Database alc - -- \connect template1 werner CREATE DATABASE "alc" WITH TEMPLATE = template0 ENCODING = 'SQL_ASCII'; etc. etc. What is the reason for this strange behaviour? I'm running PostgreSQL 7.2 on SuSE 7.2 - -- - -------------------------------------------------------------- ALC Computertechnik GmbH Kaiserstr. 100, D-52134 Herzogenrath, GERMANY Fon +49 2407 95810 Fax +49 2407 958139 http://www.alc.de - -------------------------------------------------------------- Werner Modenbach modenbach@alc.de - -------------------------------------------------------------- -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.6 (GNU/Linux) Comment: For info see http://www.gnupg.org iD8DBQE9Esk83dsyHy9PfoYRAvSYAKCZIRJmGz6WGEQCJk6CO7FwS8IqlQCffbbt OR2Z/TK6RkNbs6cb+nakt/A= =H67X -----END PGP SIGNATURE-----