Received: from maia.hub.org (maia-2.hub.org [200.46.204.251]) by mail.postgresql.org (Postfix) with ESMTP id 0A4601337B6E for ; Sat, 1 Jan 2011 13:13:38 -0400 (AST) 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 77947-02 for ; Sat, 1 Jan 2011 17:13:30 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from cronos.madness.at (madness.at [217.196.146.217]) by mail.postgresql.org (Postfix) with ESMTP id 927AC1337B56 for ; Sat, 1 Jan 2011 13:13:30 -0400 (AST) Received: from gatekeeper.kaltenbrunner.cc ([83.215.243.9] helo=[192.168.8.22]) by cronos.madness.at with esmtpsa (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.69) (envelope-from ) id 1PZ51B-0005BH-C9; Sat, 01 Jan 2011 18:13:27 +0100 Message-ID: <4D1F60B4.1060408@kaltenbrunner.cc> Date: Sat, 01 Jan 2011 18:13:24 +0100 From: Stefan Kaltenbrunner User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1.15) Gecko/20101030 Iceowl/1.0b1 Icedove/3.0.10 MIME-Version: 1.0 To: Simon Riggs CC: Robert Haas , Jeff Janes , pgsql-hackers@postgresql.org Subject: Re: Sync Rep Design References: <1293729972.1892.23804.camel@ebony> <4D1CC47E.7050207@kaltenbrunner.cc> <1293735853.1892.24886.camel@ebony> <4D1CEEAF.8050209@kaltenbrunner.cc> <1293744235.1892.26478.camel@ebony> <4D1D93F1.80602@kaltenbrunner.cc> <1293791171.1892.36233.camel@ebony> <4D1F3437.10503@kaltenbrunner.cc> <4D1F4453.50903@kaltenbrunner.cc> <1293900957.1892.60412.camel@ebony> In-Reply-To: <1293900957.1892.60412.camel@ebony> 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=-1.9 tagged_above=-5 required=5 tests=BAYES_00=-1.9 X-Spam-Level: X-Archive-Number: 201101/21 X-Sequence-Number: 177858 On 01/01/2011 05:55 PM, Simon Riggs wrote: > On Sat, 2011-01-01 at 16:12 +0100, Stefan Kaltenbrunner wrote: > >> I still would like to get a statement on why simon thinks that >> the design heikki and others have proposed > > I've explained in huge detail why I think what I think, nor avoided any > technical issue. > > It appears to me there has been substantial confusion over alternatives, > because of a misunderstanding about how synchronisation works. Requiring > confirmation that standbys are in sync is *not* the same thing as them > actually being in sync. Every single proposal made by anybody here on > hackers that supports multiple standby servers suffers from the same > issue: when the primary crashes you need to work out which standby > server is ahead. aaah that was exactly what I was after - so the problem is that when you have a sync standby it will technically always be "in front" of the master (because it needs to fsync/apply/whatever before the master). In the end the question boils down to what is "the bigger problem" in the case of a lost master: a) a transaction that was confirmed on the master but might not be on any of the surviving sync standbys (or you will never know if it is) - this is how I understand the proposal so far b) a transaction that was not yet confirmed on the master but might have been applied on the surving standby before the desaster - this is what I understand "confirm from all sync standbys" could result in. Spelled out that more clearly now makes me a bit reconsider on what I said before but I still wonder if ultimately we will have to provide both modes to satisfy different business requirements (a might provide the more accurate answer on average but b might at least provide a way to identify the "wild" transaction buy looking at additional data) > > >> - The docs should not allege that either setup is preferable to the >>> other, because there is not now and will never be consensus that this >>> is in fact true. > > I remain hopeful that people will read what I have read and understand > it. Having taken the trouble to do that publicly, my conscious is clear > that I've done the very best to explain things and make it easy for > users to avoid error. If I am prevented from putting sound advice into > the docs, I'll not worry too much. > > >> well I should think we need to clearly spell out everything that affects >> reliability and if we only support semi-sync for more than 1 standby we >> have only that setup :) > > You can use sync rep with 1 or more standby servers. > > At the end of the day, I can't stop anyone from saying "What an idiot, > he designed something that gave the same durability and availability as > Oracle and MySQL do, yet with additional performance management > features". ok Stefan