As a vRealize Automation system administrator, you must perform an appliance database maintenance failover operation.

About this task

This scenario assumes that the current master node is up and running normally. There are two database failover maintenance steps: maintenance of the master and maintenance of a replica node. When a master node has been replaced so that it becomes a replica, you should perform maintenance on it so that it is suitable to become the master again should the need arise.

Note:

Do not stop or restart the HAProxy service on the applicable host machine while performing a maintenance failover.

Prerequisites

  • vRealize Automation is installed and configured according to appropriate instructions in Installing vRealize Automation.

  • Log in to the vRealize Automation management console as root.

  • Install and configure an appropriate embedded Postgres appliance database cluster.

  • If your database uses synchronous replication mode, ensure that there are at least three active nodes in the cluster.

Procedure

  1. Remove the master node IP address from the external load balancer.
  2. Isolate the master node.

    Disconnect the node from its current network. This should be the network that is routing to the remaining vRealize Automation appliance nodes.

  3. Select another NIC for management, or manage it directly from the Virtual Appliance Management Interface.
  4. Select vRA Settings > Database on the Virtual Appliance Management Interface.
  5. Select the replica node with the lowest priority for promotion to the master, and click Promote.

    Replica nodes appear in ascending priority order.

    The old master is demoted to replica status, and the new master is promoted.

  6. Perform the appropriate replica maintenance.
  7. When the maintenance is complete, ensure that the virtual appliance is running with network connectivity and that its HAProxy service is running.
    1. Log in to the vRealize Automation management console as root.
    2. Ensure that the replica node can be pinged, resolved by name, and has a recent status in the Virtual Appliance Management Console Database tab.
  8. Click Reset for the replica node.

    This operation resets the database so that it is configured to replicate to the current master and re-synchronizes the replica node with the latest haproxy configuration from the master node.

  9. Following successful reset, return the replica virtual appliance node IP address to the external virtual appliance load balancer IP address pool.
  10. Ensure that the replica node appears healthy on the Configure Postgres vRA Database table and that it can be pinged and resolved by name.

What to do next

Correct issues with the former master node and add it back to the cluster.