Re: PostgreSQL 9.3 synchronous replication

From: Vladimir Borodin <root(at)simply(dot)name>
To: Sergey Arlashin <sergeyarl(dot)maillist(at)gmail(dot)com>
Cc: pgsql-admin <pgsql-admin(at)postgresql(dot)org>
Subject: Re: PostgreSQL 9.3 synchronous replication
Date: 2015-01-21 11:19:05
Message-ID: 8491EB60-8281-4890-A02D-DC8FF6630D70@simply.name
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin


> 21 янв. 2015 г., в 11:25, Sergey Arlashin <sergeyarl(dot)maillist(at)gmail(dot)com> написал(а):
>
> Hi!
>
> Recently I've found out that synchronous replication just guarantees that the commit has reached the transaction log on the slave. Therefore that doesn't mean the slave has replayed the transaction log and a query against the slave will show the transaction's results.
>
> So I'm wondering if there is a way to ensure that once a transaction is committed the data is available on the slave and I can get it by executing a query against the slave?

You should set synchronous_commit = on (seems, that right now you have remote_write). See http://www.postgresql.org/docs/current/static/runtime-config-wal.html#GUC-SYNCHRONOUS-COMMIT <http://www.postgresql.org/docs/current/static/runtime-config-wal.html#GUC-SYNCHRONOUS-COMMIT> for more details.

>
> --
> Best regards,
> Sergey Arlashin
>
> --
> Sent via pgsql-admin mailing list (pgsql-admin(at)postgresql(dot)org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-admin

--
May the force be with you...
http://simply.name

In response to

Responses

Browse pgsql-admin by date

  From Date Subject
Next Message Matheus de Oliveira 2015-01-21 11:34:06 Re: PostgreSQL 9.3 synchronous replication
Previous Message Harshad Adalkonda 2015-01-21 11:15:15 Re: pg_upgrade vs. pg_dump