Delete a vRouter node

Tungsten Fabric vRouter collocates with the OpenStack compute node. Therefore, to delete the vRouter node from your cluster, follow the node deletion procedure in Delete a compute node.

Additionally, you need to remove the vhost0 OpenStack port and the Node object of the deleted node from the Tungsten Fabric database:

  1. Log in to the keystone-client pod in the openstack namespace through the command line.

  2. Obtain the OpenStack token required to authenticate with the Tungsten Fabric API service:

    TOKEN=$(openstack token issue | awk '/ id / {print $4}')
    
  3. Obtain the list of vRouter nodes to retrieve the link for the deleted node:

    curl -s -H "X-Auth-Token: ${TOKEN}" http://tf-config-api.tf.svc:8082/virtual-routers | jq
    
  4. Obtain the UUID of the vhost0 port to be removed:

    curl -s -H "X-Auth-Token: ${TOKEN}" http://tf-config-api.tf.svc:8082/virtual-router/<VROUTER_UUID> | jq '.["virtual-router"]["virtual_machine_interfaces"][0]["uuid"]'
    
  5. Delete the vhost0 OpenStack port through the Openstack Horizon or CLI:

    openstack port delete <VHOST0_PORT_UUID>
    
  6. Delete the vRouter Node object from the Tungsten Fabric configuration database:

    curl -s -X DELETE -H "X-Auth-Token: ${TOKEN}" http://tf-config-api.tf.svc:8082/virtual-router/<VROUTER_NODE_UUID>