Received: from localhost (unknown [200.46.204.183]) by mail.postgresql.org (Postfix) with ESMTP id 4FDCA650038 for ; Mon, 17 Nov 2008 11:33:00 -0400 (AST) Received: from mail.postgresql.org ([200.46.204.86]) by localhost (mx1.hub.org [200.46.204.183]) (amavisd-maia, port 10024) with ESMTP id 83747-02 for ; Mon, 17 Nov 2008 11:32:55 -0400 (AST) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from outmail129173.authsmtp.com (outmail129173.authsmtp.com [62.13.129.173]) by mail.postgresql.org (Postfix) with ESMTP id B945464FD92 for ; Mon, 17 Nov 2008 11:32:55 -0400 (AST) Received: from mail-c193.authsmtp.com (mail-c193.authsmtp.com [62.13.128.118]) by punt8.authsmtp.com (8.14.2/8.14.2/Kp) with ESMTP id mAHFWKTP013594; Mon, 17 Nov 2008 15:32:20 GMT Received: from [192.168.0.3] (85-211-229-157.dyn.gotadsl.co.uk [85.211.229.157]) (authenticated bits=0) by mail.authsmtp.com (8.14.2/8.14.2/Kp) with ESMTP id mAHFWI7F024479; Mon, 17 Nov 2008 15:32:19 GMT Subject: Re: [PATCHES] Infrastructure changes for recovery (v8) From: Simon Riggs To: Heikki Linnakangas Cc: pgsql-hackers In-Reply-To: <49217D3F.9050603@enterprisedb.com> References: <1222815151.4445.1397.camel@ebony.2ndQuadrant> <48EC9CC5.6060803@enterprisedb.com> <1223468660.4747.294.camel@ebony.2ndQuadrant> <1223472898.4747.310.camel@ebony.2ndQuadrant> <49217D3F.9050603@enterprisedb.com> Content-Type: text/plain Date: Mon, 17 Nov 2008 15:33:13 +0000 Message-Id: <1226935993.3790.12.camel@ebony.2ndQuadrant> Mime-Version: 1.0 X-Mailer: Evolution 2.12.0 Content-Transfer-Encoding: 7bit X-Server-Quench: ebd59705-b4bc-11dd-8a51-002264978518 X-AuthRoute: OCdxZQATClZOTQEd DAteCiNZVAwpPBRK HVkIKg5MJUcNSQVJ NksadBtFaQJbY1ZH HGQLW1xEUVh7WmF/ agMfZQBDYEtPQQdo WVZIR1VNFgBqBAMB SENvKm8VDgIweHx0 YUFrEHFdWUM0IBQp R0dTFWgbN2MyO30e URQMagsFdQJXfh9H aFZ7XXQFZGQPKBg1 TUcABxkNFhVyExEd YwcDN1sJXVwWFSIh XR1KFjUmG0IIXG09 KAZuMFMXG1gcKFR6 cUVxGDpf X-Authentic-SMTP: 61633235383639.pelican.dmpriest.net.uk:1378/Kp X-Report-SPAM: If SPAM / abuse - report it at: http://www.authsmtp.com/abuse X-Virus-Status: No virus detected - but ensure you scan with your own anti-virus system! X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0 tagged_above=0 required=5 tests=none X-Spam-Level: X-Archive-Number: 200811/1150 X-Sequence-Number: 127862 On Mon, 2008-11-17 at 16:18 +0200, Heikki Linnakangas wrote: > > + > > + /* > > + * Load the flat authorization file into > postmaster's ca > > + * startup process won't have recomputed > this from the d > > + * yet, so it may change following recovery. > > + */ > > + load_role(); > > Is there a race condition here too, if the startup process is writing > the auth file at the same time? I guess we'd have the same problem > with flat files in general, so maybe there's something else that > mitigates the problem? The flat file is not race condition proof. When the file is read it is just a guide and the real data is re-accessed from catalog. So the problem you see does exist, but is handled elsewhere - not in this patch. -- Simon Riggs www.2ndQuadrant.com PostgreSQL Training, Services and Support