Re: Configuring synchronous replication

From: Simon Riggs <simon(at)2ndQuadrant(dot)com>
To: Heikki Linnakangas <heikki(dot)linnakangas(at)enterprisedb(dot)com>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Robert Haas <robertmhaas(at)gmail(dot)com>, jd(at)commandprompt(dot)com, Thom Brown <thom(at)linux(dot)com>, Bruce Momjian <bruce(at)momjian(dot)us>, Andrew Dunstan <andrew(at)dunslane(dot)net>, Dave Page <dpage(at)pgadmin(dot)org>, Peter Eisentraut <peter_e(at)gmx(dot)net>, Fujii Masao <masao(dot)fujii(at)gmail(dot)com>, Josh Berkus <josh(at)agliodbs(dot)com>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Configuring synchronous replication
Date: 2010-09-23 22:11:43
Message-ID: 1285279903.17321.1221.camel@ebony
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers pgsql-hackers

On Thu, 2010-09-23 at 20:42 +0300, Heikki Linnakangas wrote:
> If you want the behavior where the master doesn't acknowledge a
> commit
> to the client until the standby (or all standbys, or one of them
> etc.)
> acknowledges it, even if the standby is not currently connected, the
> master needs to know what standby servers exist. *That's* why
> synchronous replication needs a list of standby servers in the master.
>
> If you're willing to downgrade to a mode where commit waits for
> acknowledgment only from servers that are currently connected, then
> you don't need any new configuration files.

As I keep pointing out, waiting for an acknowledgement from something
that isn't there might just take a while. The only guarantee that
provides is that you will wait a long time. Is my data more safe? No.

To get zero data loss *and* continuous availability, you need two
standbys offering sync rep and reply-to-first behaviour. You don't need
standby registration to achieve that.

> But that's not what I call synchronous replication, it doesn't give
> you the guarantees that
> textbook synchronous replication does.

Which textbook?

--
Simon Riggs www.2ndQuadrant.com
PostgreSQL Development, 24x7 Support, Training and Services

In response to

Responses

Browse pgsql-committers by date

  From Date Subject
Next Message Robert Haas 2010-09-24 02:09:13 pgsql: Add contrib/xml2/pgxml.sql to .gitignore
Previous Message Robert Haas 2010-09-23 21:47:43 pgsql: Replace doc references to install-win32 with install-windows.

Browse pgsql-hackers by date

  From Date Subject
Next Message Kevin Grittner 2010-09-23 23:58:40 Re: .gitignore files, take two
Previous Message Tom Lane 2010-09-23 22:04:58 Re: git cherry-pick timestamping issue