Postgres 9.6 active-passive HA cluster

From: Jairam Gauns <jairam(dot)gauns(at)gmail(dot)com>
To: pgsql-general(at)lists(dot)postgresql(dot)org
Subject: Postgres 9.6 active-passive HA cluster
Date: 2019-10-16 10:25:55
Message-ID: CABi+Qf8+oHW1tv7ykqv3R4rjm-K+taf3Wz9kcogaFz9OECqL9w@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hi guys,

We are in process of testing a Postgres 9.6 active-passive HA cluster using

streaming replication on Rhel 7.6.

We have setup Postgres 9.6 primary/warm standby streaming synchorous
replication.

We have set synchronous_standby_names=* and synchronous_commit=on.

To test we have 5 sql clients firing inserts simultaneously on the 12
tables created on a db present on the primary. each client would end up
firing 2000 request.

So when i run this experiment, i kill postgres on primary say after 8000
records are inserted.

Then i start both nodes as standalone to compare the data.

So once in a while i observe that there exist one record more in a few
tables on the killed primary than as compared to the records on the
standby.

Our expectation is both servers should have same number of records when we
set synchronous replication. Because if that does not happen and now i make
the failed primary the new standby then the records would not be saved as
the new primary(old standby) did not have them in the first place.
How do we handle this situation?

Could anybody please help provide some pointers?

Thanks
Jairam

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Francisco Olarte 2019-10-16 10:33:13 Re: Is there any configuration in postgresql.conf or any other configuration of postgres which will make this possible to listen on particular interface
Previous Message M Tarkeshwar Rao 2019-10-16 10:07:33 Is there any configuration in postgresql.conf or any other configuration of postgres which will make this possible to listen on particular interface