X-Original-To: pgsql-admin-postgresql.org@postgresql.org Received: from localhost (wm.hub.org [200.46.204.128]) by postgresql.org (Postfix) with ESMTP id 1CA629FA50D for ; Mon, 17 Jul 2006 12:23:33 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.128]) (amavisd-new, port 10024) with ESMTP id 80289-08 for ; Mon, 17 Jul 2006 15:23:22 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey- Received: from exchange.g2switchworks.com (mail.g2switchworks.com [63.87.162.25]) by postgresql.org (Postfix) with ESMTP id 502379FA506 for ; Mon, 17 Jul 2006 12:23:23 -0300 (ADT) Received: from 10.10.1.37 ([10.10.1.37]) by exchange.g2switchworks.com ([10.10.1.2]) with Microsoft Exchange Server HTTP-DAV ; Mon, 17 Jul 2006 15:23:17 +0000 Received: from state.g2switchworks.com by mail.g2switchworks.com; 17 Jul 2006 10:23:17 -0500 Subject: Re: Recycle error logs From: Scott Marlowe To: adey Cc: "pgsql-admin@postgresql.org" , postgresql-l In-Reply-To: <1c66bda80607150037j3c127a32tcdade264bc3f583e@mail.gmail.com> References: <1c66bda80607150037j3c127a32tcdade264bc3f583e@mail.gmail.com> Content-Type: text/plain Content-Transfer-Encoding: 7bit Message-Id: <1153149797.2744.49.camel@state.g2switchworks.com> Mime-Version: 1.0 X-Mailer: Ximian Evolution 1.4.6 (1.4.6-2) Date: Mon, 17 Jul 2006 10:23:17 -0500 X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200607/142 X-Sequence-Number: 22388 On Sat, 2006-07-15 at 02:37, adey wrote: > Please advise if there is a way to start a fresh Postgresql error / > output log at regular intervals? > We are tuning a "new toproduction" system, so I have all the SQL > logged, but the file gets too big and cumbersome, so I'd like to start > a new one each morning without restarting Postgres. As mentioned previously, it's built into 8.0 and up. If you're stuck on a version before that, you can use apache's log rotator to do the job. Something like this: pg_ctl start | /usr/sbin/rotatelogs /logs/pgsql 86400