Unregister VCD standby node with CURL command
search cancel

Unregister VCD standby node with CURL command

book

Article ID: 335232

calendar_today

Updated On:

Products

VMware Cloud Director

Issue/Introduction

Unregister all standby nodes to recover the VCD appliance.


Symptoms:

After recover the VCD cluster from incorrect snapshot, standby nodes not running.

  • 5480 shows primary node is running
  • 5480 shows standby node is unreachable
  • 5480 shows the cluster health is READ ONLY PRIMARY
  • Provider UI is not responding, Unable to get API token from UI.


Environment

VMware Cloud Director 10.x

Cause

By default, the database nodes will continue to synchronize. Due to an error in the standby node, the database service cannot be used normally, resulting in an error in database synchronization.

Resolution

1. Enable SSH to VCD Primary Node.

2. SSH to VCD Primary Node with root user.

3. Get the bearer Token with curl command

curl -k -X POST -u root "https://VCD_IP_or_FQDN:5480/api/1.0.0/sessions"

4. Verify the token is usable with Get request.

curl -k -X GET -H "Authorization: Bearer xxx" "https://VCD_IP_or_FQDN:5480/api/1.0.0/version"

5. Run the DELETE request to unregister standby nodes.

curl -k -X DELETE -h "Accept: application/json" -H "Authorization: Bearer xxx" "https://VCD_IP_or_FQDN:5480/api/1.0.0/nodes/standby_node_name"

6. Refresh the VAMI page, the standby node should no longer appear.