2 node cluster not able to make failed node Standby Node

15 views
Skip to first unread message

aman kumar

unread,
Jan 23, 2023, 6:03:39 AMJan 23
to repmgr
Hi Team,

We have two node(Node1 & Node2) cluster.
Postgres version - 14.6
repmgr - 5

Issues: When Node1(Primary) goes down Node2(Standby) promotes to Primary as expected But When Node1 comes UP then it also work as Primary which should not be a case.

Below are the coresponding repmgr.config file

repmgr.config file
node_id=1
node_name='node1'
conninfo='host=node1_IP user=repmgr dbname=repmgr connect_timeout=2'
data_directory='/var/lib/pgsql/14/data'
failover=automatic
promote_command='/usr/pgsql-14/bin/repmgr standby promote -f /etc/repmgr.conf --log-to-file'
follow_command='/usr/pgsql-14/bin/repmgr standby follow -f /etc/repmgr.conf --log-to-file --upstream-node-id=2'
log_file='/var/log/repmgr/repmgr.log'
always_promote=true


repmgr.config file
node_id=2
node_name='node2'
conninfo='host=node2_IP user=repmgr dbname=repmgr connect_timeout=2'
data_directory='/var/lib/pgsql/14/data'
failover=automatic
promote_command='/usr/pgsql-14/bin/repmgr standby promote -f /etc/repmgr.conf --log-to-file'
follow_command='/usr/pgsql-14/bin/repmgr standby follow -f /etc/repmgr.conf --log-to-file --upstream-node-id=2'
log_file='/var/log/repmgr/repmgr.log'
always_promote=true




Reply all
Reply to author
Forward
0 new messages