Repairing the Cluster
An example of when you might try running the replication repair command is if you find that replication between the two cluster nodes is out of sync (refer to Showing the Replication Status). Check your log files in /var/log/replication/repl.log or via the UI (Administration > Replication > Status), then expand the node information and click on the Log buttons) for indication of this type of "fatal error." Running the replication repair command may fix this sync issue.
The following command (and corresponding output) is an example from the cluster that was shown in Configuring an Active - Standby Replication
# replication repair
------------------------------------------------------------------------------
* You will be prompted for the password of local system.
------------------------------------------------------------------------------
[sudo] password for cpn_service:
------------------------------------------------------------------------------
WARNINGS:
1. Database Replication Repair routine must be performed on the database
node whose database is in good condition and will provide a replication
base during the database repair process. Before proceeding, create a VM
snapshot of this database node.
2. During Database replication repair, any data existing on the other
database node will be deleted and replaced with the data currently on
this node.
------------------------------------------------------------------------------
Do you want to continue? [y/n]
Please answer yes or no.
Do you want to continue? [y/n] y
------------------------------------------------------------------------------
WARNING:
Database cluster has been setup:
Local Node: 192.168.94.243 ssh port# 8022
Remote Node: 192.168.94.244 ssh port# 8022
During database replication repair, any data existing on the remote node
will be deleted and replaced with the data currently on the local node.
------------------------------------------------------------------------------
Do you want to continue? [y/n] y
Checking remote node 192.168.94.244 ...
Will start database replication repair ...
Will set maintenance mode for remote node 192.168.94.244 ...
ts=20190821 180936.427, lvl=INFO, action=RUN_SCRIPT, script=update-httpd-mainten ance, message=Executing...
ts=20190821 180936.430, lvl=INFO, action=RUN_SCRIPT, script=update-httpd-mainten ance, message= - Param: /etc/httpd/conf/httpd.conf
ts=20190821 180936.444, lvl=INFO, action=RUN_SCRIPT, script=update-httpd-mainten ance, message=Will enable maintenance mode restriction in httpd conf...
ts=20190821 180936.453, lvl=INFO, action=RUN_SCRIPT, script=update-httpd-mainten ance, message=Done.
Will stop local cluster monitoring service on 192.168.94.243 ...
Will stop remote cluster monitoring service on 192.168.94.244 ...
Will stop database replication on 192.168.94.243 ...
Will stop remote database replication on 192.168.94.244 ...
Will transfer application database to the secondary database node at 192.168.94. 244 ...
Will provision new remote node 192.168.94.244 ...
Done provisioning new remote node 192.168.94.244 :
Will unset maintenance mode for the remote node 192.168.94.244 ...
ts=20190821 180955.302, lvl=INFO, action=RUN_SCRIPT, script=update-httpd-mainten ance, message=Executing...
ts=20190821 180955.305, lvl=INFO, action=RUN_SCRIPT, script=update-httpd-mainten ance, message= - Param: /etc/httpd/conf/httpd.conf
ts=20190821 180955.321, lvl=INFO, action=RUN_SCRIPT, script=update-httpd-mainten ance, message=Will not enable maintenance mode restriction in httpd conf.
ts=20190821 180955.332, lvl=INFO, action=RUN_SCRIPT, script=update-httpd-mainten ance, message=Done.
Will start local cluster monitoring service 192.168.94.243 ...
Will start remote cluster monitoring service on 192.168.94.244 ...
Database replication repair completed.
#After the repair process completes, run the replication show-status command again to see if the issue appears to be resolved. Also, check your log files again.