Unable to add ESXI host as a host transport node.
search cancel

Unable to add ESXI host as a host transport node.

book

Article ID: 319978

calendar_today

Updated On:

Products

VMware NSX VMware NSX-T Data Center

Issue/Introduction

1.  When attempting to prepare a ESXI host as a host transport node, the process fails with an indication that the NSX Manager cannot find the record for the host, referencing old metadata elements for that host, i.e. old IP different external uuid.

  • "Node <uuid> with same ip <ip-address> already exists", etc.

2.  You receive the following error while trying to configure NSX on ESXi host

  • "Error: Operation cannot be performed as the object(s) has been updated by another user while you were trying. Refresh and try again. (Error code: 500071)".

Environment

  • VMware NSX-T Data Center
  • VMware NSX

Cause

This behavior is caused by a partial record for a host transport node that includes metadata that references the host that is trying to prepare as a host transport node.  The TN creation workflow can halt prematurely while retrieving the thumbprint for the host certificate.

If the certificate is not in the correct format ( a common causes extra spaces or formatting characters in the certificate body) this will cause a parsing failure and leave a partial record for that host.

Resolution

Before going to the Corfu database it may be possible to force a cleanup using REST API commands

You can validate the deletion by running the below API:  GET api/v1/transport-nodes/<TN UUID>/state

    1. Before running The above API call, run through the below steps.
    2. "Remove NSX" from host in question in the NSX UI (or remove host from cluster if Transport Node Profile is present on cluster).
    3. Ensure NSX VIBs have been removed from the host.  Run the following command on ESXI host.  esxcli software vib list | grep nsx
    4. There should be nothing present, but if VIBs are still present and NSX UI shows host is no longer configured proceed with running the command below:
        • nsxcli del nsx
        • reboot of the host is recommended.
    5. Search NSX UI for the host name of the ESXi host in question and if a UUID shows up, copy it out for the above API call.
    6. If you are unable to find the UUID of the host in NSX UI, Open a new SSH session into the host and run the following command: esxcli system uuid get



    7. Execute above API call with UUID obtained from step 4.
      • If you don't have access to Postman, run the following CURL command on any one of the (3) NSX managers from root mode.
      • curl -l -k -u 'admin' -H 'Content-Type:application/json' -X DELETE  "https://localhost/api/v1/transport-nodes/<transport-node-UUID-goes-here>?force=true&unprepare_host=false"
    8. From admin cli mode on ALL (3) NSX managers, run "start search resync all"
    9. Log out of NSX UI and log back in (reindexing may take a few minutes)
    10. Check NSX search for host name in question to ensure no UUID shows up.
    11. Re-install NSX on host in question by moving it back into the cluster.  The re-installation will automate and you can view the status from the NSX UI.