X-Original-To: pgsql-admin-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by postgresql.org (Postfix) with ESMTP id A1B479DC822 for ; Thu, 19 Jan 2006 13:02:02 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 56420-04 for ; Thu, 19 Jan 2006 13:01:59 -0400 (AST) X-Greylist: from auto-whitelisted by SQLgrey- Received: from sss.pgh.pa.us (sss.pgh.pa.us [66.207.139.130]) by postgresql.org (Postfix) with ESMTP id 37E859DCA43 for ; Thu, 19 Jan 2006 13:01:58 -0400 (AST) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.13.1/8.13.1) with ESMTP id k0JH1pGJ017320; Thu, 19 Jan 2006 12:01:51 -0500 (EST) To: Chris Jewell cc: pgsql-admin@postgresql.org Subject: Re: WAL log archive frequency In-reply-to: <43CF6D93.2080806@lancaster.ac.uk> References: <43CF6D93.2080806@lancaster.ac.uk> Comments: In-reply-to Chris Jewell message dated "Thu, 19 Jan 2006 10:44:35 +0000" Date: Thu, 19 Jan 2006 12:01:51 -0500 Message-ID: <17319.1137690111@sss.pgh.pa.us> From: Tom Lane X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, score=0.092 required=5 tests=[AWL=0.092] X-Spam-Score: 0.092 X-Spam-Level: X-Archive-Number: 200601/219 X-Sequence-Number: 20307 Chris Jewell writes: > Further to my question on PITR, I have now implemented it :-) However, > I was wondering about the frequency of archiving the WAL. Does > postgresql wait until the current WAL file has reached 16MB before > calling the archive_command? Yes. The assumption is the archive_command may be too stupid to deal with archiving the same file more than once, and/or might have performance issues with doing that, eg, if it's writing to tape or some kind of write-once media. You can do something like saving the newest-by-timestamp file in the xlog directory every minute or whatever via a cron job. This ought to be better integrated though ... regards, tom lane