Received: from maia.hub.org (unknown [200.46.204.251]) by mail.postgresql.org (Postfix) with ESMTP id D11C61337999 for ; Fri, 22 Oct 2010 14:18:23 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.251]) (amavisd-maia, port 10024) with ESMTP id 08789-08 for ; Fri, 22 Oct 2010 17:18:15 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from glacier.frostconsultingllc.com (glacier.frostconsultingllc.com [69.36.227.170]) by mail.postgresql.org (Postfix) with ESMTP id 762B51337B8F for ; Fri, 22 Oct 2010 14:18:15 -0300 (ADT) Received: from dsl081-245-111.sfo1.dsl.speakeasy.net ([64.81.245.111] helo=[192.168.1.118]) by glacier.frostconsultingllc.com with esmtpsa (TLSv1:CAMELLIA256-SHA:256) (Exim 4.69) (envelope-from ) id 1P9LFn-0007oM-8M; Fri, 22 Oct 2010 10:18:09 -0700 Message-ID: <4CC1C74E.8080409@agliodbs.com> Date: Fri, 22 Oct 2010 10:18:06 -0700 From: Josh Berkus User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1.9pre) Gecko/20100217 Shredder/3.0.3pre MIME-Version: 1.0 To: Fujii Masao CC: Robert Haas , Bruce Momjian , Greg Stark , pgsql-hackers@postgresql.org Subject: Re: Simplifying replication References: <201010220058.o9M0waa06053@momjian.us> <4CC0E465.4000700@agliodbs.com> <4CC0F10D.3000201@agliodbs.com> In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=2.419 tagged_above=-5 required=5 tests=BAYES_00=-1.9, FS_REPLICA=3.599, SARE_SPEC_REPLICA=0.72 X-Spam-Level: ** X-Archive-Number: 201010/1656 X-Sequence-Number: 172696 > Please see > http://archives.postgresql.org/pgsql-docs/2010-10/msg00038.php Ye gods and little fishes! You really want to talk arcane formulas. I've re-read that three times, and am still not sure that I could tell someone definitively how much disk space WAL needs for a given group of settings. I'll also point out that that formula is not in our docs -- what's an appropriate location? I think this needs to be corrected in 9.1, *even if it means breaking backwards compatibility*. What would be sensible for DBAs is to have two settings: max_wal_size min_wal_size These would be expresses in MB or GB and would be simple direct quantities, which our formulas would work backwards from. max_wal_size would be a hard limit (i.e. Postgres would stop accepting writes if we hit it), and Admins would not be allowed to set min_wal_size to more than max_wal_size - 2. Even better would be to replace min_wal_size with min_wal_time, which would set a time span for the oldest WAL segment to be kept (up to max_wal_size - 2). Hmmm. That doesn't seem that hard to implement. Is it? (BTW, Robert, that e-mail is what I meant by "relationship") -- -- Josh Berkus PostgreSQL Experts Inc. http://www.pgexperts.com