search cancel

How to sync two sperate 2 node clusters


Article ID: 253589


Updated On:


CA API Gateway


We have two sperate environments of 2 node clusters, currently manual modify and objects two each cluster.  The is a difference in the certificates of the ID Provider resulting in failures to one cluster only.

What's the best approach to sync these two environments 






Release : 10.0


Manual changes are prone for errors 


Best approach is to dump the SSG DB form the good cluster then import into the second cluster

The steps are similar to clone and the KB for re-init replication

NOTE Check with the team regarding cluster passphrase between the two different cluster 

 First dump the SSG DB from the node in the good cluster

 #  mysqldump ssg --routines > /home/ssgconfig/01-ssg.sql

Copy the backup-ssg.sql to the problem each node in the cluster


On the problem cluster 

STOP SSG services on both gateways 

# service ssg stop


Stop slave replication on both nodes: 

# mysqladmin stop-replica 


Reset the master configuration on both nodes: 

# mysql -e "reset master"

# mysql -e "reset slave; reset slave all;"


Backup current SSG DB on problem gateway as a precaution 

mysqldump ssg --routines > /home/ssgconfig/03-ssg.sql


Drop the SSG from the BOTH gateway’s and import the SSG DB from the good cluster to both

# mysql

# drop database ssg;

# create database ssg;

# mysql -u root -p ssg < 01-ssg.sql


Clear cluster_info table on BOTH Gateways

# mysql

mysql> use ssg;app*A

mysql> truncate table cluster_info;


SETUP replication Secondary gateway and restart replication on the primary node

  1. Execute the script on the SECONDARY node: /opt/SecureSpan/Appliance/bin/
    • Follow the prompts of the script, keeping the following in mind:
      • Provide the FQDN of the primary node
      • Enter NO to the prompt "Do you want to clone a database from $Master (yes or no)?"
  2. Execute the script on the PRIMARY node: /opt/SecureSpan/Appliance/bin/
    • Follow the prompts of the script, keeping the following in mind:
      • Provide the FQDN of the secondary node
  3. Query the status of the replication on both nodes: mysql -e "show slave status\G"
  4. Verify both nodes return the following lines:

Slave_IO_Running: Yes
Slave_SQL_Running: Yes
Seconds_Behind_Master: 0

  1. Start the Gateway 'ssg' service on both nodes: service ssg start