Received: from maia.hub.org (maia-2.hub.org [200.46.204.251]) by mail.postgresql.org (Postfix) with ESMTP id 843BEB5DBCE for ; Tue, 27 Sep 2011 03:07:35 -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 41882-07 for ; Tue, 27 Sep 2011 06:07:29 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.8.0-rc2 Received: from exprod7og112.obsmtp.com (exprod7og112.obsmtp.com [64.18.2.177]) by mail.postgresql.org (Postfix) with ESMTP id 9587CB5DBCD for ; Tue, 27 Sep 2011 03:07:28 -0300 (ADT) Received: from mail-wy0-f174.google.com ([74.125.82.174]) (using TLSv1) by exprod7ob112.postini.com ([64.18.6.12]) with SMTP ID DSNKToFoH3V0RvAh7i2JQah4r9Owic/FOz7A@postini.com; Mon, 26 Sep 2011 23:07:29 PDT Received: by mail-wy0-f174.google.com with SMTP id 34so8280417wyg.5 for ; Mon, 26 Sep 2011 23:07:27 -0700 (PDT) Received: by 10.227.38.217 with SMTP id c25mr6783530wbe.60.1317103187997; Mon, 26 Sep 2011 22:59:47 -0700 (PDT) Received: from [172.20.9.94] ([62.96.109.122]) by mx.google.com with ESMTPS id s30sm4425303wbm.12.2011.09.26.22.59.45 (version=TLSv1/SSLv3 cipher=OTHER); Mon, 26 Sep 2011 22:59:46 -0700 (PDT) Message-ID: <4E816650.80607@enterprisedb.com> Date: Tue, 27 Sep 2011 07:59:44 +0200 From: Heikki Linnakangas User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; fi-FI; rv:1.9.2.21) Gecko/20110831 Icedove/3.1.13 MIME-Version: 1.0 To: Florian Pflug CC: Tom Lane , Simon Riggs , Fujii Masao , PostgreSQL-development Subject: Re: bug of recovery? References: <889.1317069556@sss.pgh.pa.us> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-15; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.9 tagged_above=-5 required=5 tests=BAYES_00=-1.9 X-Spam-Level: X-Archive-Number: 201109/1446 X-Sequence-Number: 195635 On 27.09.2011 00:28, Florian Pflug wrote: > On Sep26, 2011, at 22:39 , Tom Lane wrote: >> It might be worthwhile to invoke XLogCheckInvalidPages() as soon as >> we (think we) have reached consistency, rather than leaving it to be >> done only when we exit recovery mode. > > I believe we also need to prevent the creation of restart points before > we've reached consistency. Seems reasonable. We could still allow restartpoints when the hash table is empty, though. And once we've reached consistency, we can throw an error immediately in log_invalid_page(), instead of adding the entry in the hash table. -- Heikki Linnakangas EnterpriseDB http://www.enterprisedb.com