From: Adrien Nayrat <adrien.nayrat@anayrat.info>
To: Shital A <brightuser2019@gmail.com>
To: pgsql-general@postgresql.org
Subject: Re: Fwd: Postgres HA - pacemaker RA do not support auto failback
Date: Mon, 12 Aug 2019 15:24:13 +0200
Message-ID: <8d345c0c-5673-0ea7-fe08-8d0d6bc8dbfb@anayrat.info> (raw)
In-Reply-To: <CAMp7vw9zshi6T2QNgy+GtXVVY3ag9RrZB7onsNTw0hcKrdG+ww@mail.gmail.com>
References: <CAMp7vw_KF2eM_Buh_fPbZNC9Z6PVvx+7rxjyMhfMcoZXuWGLKw@mail.gmail.com>
<CAMp7vw9zshi6T2QNgy+GtXVVY3ag9RrZB7onsNTw0hcKrdG+ww@mail.gmail.com>
On 8/12/19 2:57 PM, Shital A wrote:
>
>
> Hello,
>
> Postgres version : 9.6
> OS:Rhel 7.6
>
> We are working on HA setup for postgres cluster of two nodes in active-passive
> mode.
>
> Installed:
> Pacemaker 1.1.19
> Corosync 2.4.3
>
> The pacemaker agent with this installation doesn't support automatic failback.
> What I mean by that is explained below:
> 1. Cluster is setup like A - B with A as master.
> 2. Kill services on A, node B will come up as master.
> 3. node A is ready to join the cluster, we have to delete the lock file it
> creates on any one of the node and execute the cleanup command to get the node
> back as standby
>
> Step 3 is manual so HA is not achieved in real sense.
>
> Please help to check:
> 1. Is there any version of the resouce agent which supports automatic failback?
> To avoid generation of lock file and deleting it.
>
> 2. If there is no such support, what checks should be added in pgsql RA to achieve
>
> Please suggest.
> Thanks.
>
Hello,
Which RA did you use? AFAIK there is two RA :
- pgsql : https://github.com/ClusterLabs/resource-agents/blob/master/heartbeat/pgsql
- PAF : http://clusterlabs.github.io/PAF/ (Which is different from pgsql RA :
http://clusterlabs.github.io/PAF/FAQ.html#why-new-ra-for-postgresql)
If I am right, PAF should handle the case when there no need to perform pgrewind
(if the old master is not too advanced in the transaction log).
Regards,
--
Adrien NAYRAT
https://blog.anayrat.infoAttachments:
signature.asc (application/pgp-signature, 487B) download
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-general@postgresql.org
Cc: adrien.nayrat@anayrat.info, brightuser2019@gmail.com
Subject: Re: Fwd: Postgres HA - pacemaker RA do not support auto failback
In-Reply-To: <8d345c0c-5673-0ea7-fe08-8d0d6bc8dbfb@anayrat.info>
References: <CAMp7vw_KF2eM_Buh_fPbZNC9Z6PVvx+7rxjyMhfMcoZXuWGLKw@mail.gmail.com> <CAMp7vw9zshi6T2QNgy+GtXVVY3ag9RrZB7onsNTw0hcKrdG+ww@mail.gmail.com> <8d345c0c-5673-0ea7-fe08-8d0d6bc8dbfb@anayrat.info>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox