If your designated primary Appliance Database fails, implement a failover to the designated replica database on the secondary appliance to maintain system operation.
About this task
Configure the Appliance Database as applicable for your system configuration. See Configure the vRealize Automation Appliance Database.
- If possible, log in to the appliance hosting the primary Appliance Database as root using SSH.
If the appliance or its host machine is not running, skip to step 3.
- Stop the vpostgres service using the
service postgres stop command.
# service postgres stop Stopping Vmware vPostgres: Last login: Mon Apr 27 19:49:26 UTC 2015 on pts/0 ok
- Promote the replica database on the secondary appliance to be the primary database.
- Log in the secondary appliance as root using SSH.
- Promote the replica database to master as the postrgres user using the
# su - postgres /opt/vmware/vpostgres/current/share/promote_replica_to_primary server promoting
- Configure the database virtual IP for the new Appliance Database configuration.
VIP Configuration Option
If you are using a DNS entry for the Appliance Database, change the DNS entry point as appropriate for your system.
Modify the IP of the DNS entry to point at the new primary appliance.
Log in to each vRealize Appliance as root and execute a service network restart.
If you configured a virtual IP for the Appliance Database, edit the pool that you created containing the two vRealize Automation appliances as nodes.
Disable the old primary node.
Enable the new primary node.
- Rebuild the replica database on the original primary Appliance Database host machine.
- Log in to the appliance as root using SSH.
- Configure database replication as the postrgres user using the
./run_as_replica-h primary appliance -b-W-U replicatecommand.
# su -postgres /opt/vmware/vpostgres/current/share/run_as_replica -h appl.domain.local -b -W -U replicate
- Enter the replicate user password when prompted.
- Type yes in response to the following message.
"WARNING: the base backup operation will replace the current contents of the data directory. Please confirm by typing yes."
What to do next
Validate that the replication was successful. See Validate Appliance Database Replication.