"host switch apply operation failed" Error message received when installing NSX on a reimaged host
search cancel

"host switch apply operation failed" Error message received when installing NSX on a reimaged host

book

Article ID: 389454

calendar_today

Updated On:

Products

VMware NSX VMware NSX-T Data Center

Issue/Introduction

  • The NSX installation on host transport node failed after a host reimage. Below is a sample error message reported in the NSX UI.
  • Host configuration: host switch apply operation failed: [Error; <vDS name>|## ## ## ## ## ## ## ##-## ## ## ## ## ## ## 4e|VDS|Failed to lookup dvs: ## ## ## ## ## ## ## ##-## ## ## ## ## ## ##  4e|Nsx VDS [## ## ## ## ## ## ## ##-## ## ## ## ## ## ## 4e] is not found]; ApplyHostSwitchMode to [<vDS name>] failed : Failed to read opaque switch spec. ; DefaultGateway [<IP address>] failed to be applied: Failed to update vxlan default gateway: {'fault': 'PlatformConfigFault', 'msg': 'An error occurred during host configuration.', 'faultMessage': ['Operation failed, diagnostics report: Unable to set VMkernel gateway address to <IP address> as there are no VMkernel interfaces on the same network with that IP address.']}; VTEP [vmk10,<IP address>] failed to be applied: Failed to create/update vtep port: {'fault1': {'objectId': '########-####-####-####-##########a7', 'fault': 'NotFound', 'msg': 'The object or item referred to could not be found.', 'faultMessage': []}}; VTEP [vmk11,<IP address>] failed to be applied: Failed to create/update vtep port: {'fault1': {'objectId': '########-####-####-####-##########45', 'fault': 'NotFound', 'msg': 'The object or item referred to could not be found.', 'faultMessage': []}}; ; LogicalSwitch full-sync: LogicalSwitch full-sync realization query skipped

Environment

VMware NSX

VMware NSX-T Data Center

Cause

This issue occurs when the vDS is not found on the ESXi host, leading to the installation failure.

Resolution

This issue typically arises after a host is re-imaged, as the vDS configuration is lost.

To verify if the required vDS is present on the host, log in via CLI and run the following command:

esxcfg-vswitch -l

Ensure that the host is added to the vDS and that the vDS is not out of sync in the vCenter UI.

If the host is already added to the vDS but it does not appear on the host, you may need to disconnect and remove the ESXi host from the vCenter inventory. This action will remove the ESXi host from the vCenter DB, allowing it to be re-added to re-sync the vDS settings, as described in step 3 of this KB article below provided the host is not part of a vSAN/NSX cluster.

The vSphere Distributed Switch configuration on some hosts differed from that of VMware vCenter- "Out of Sync"

For VCF deployments, this approach might cause issues with SDDC Manager, which may not be aware of changes in the underlying infrastructure. The recommended procedure is to decommission the ESXi host from SDDC Manager. This will automatically disconnect the ESXi host and remove it from the vCenter inventory as part of the decommissioning process. Once completed, the ESXi host can be recommissioned through the SDDC Manager, although it may prompt for a re-image of the ESXi host during the commissioning process.

If you require any support to validate the issue or carry out any procedures, please open a case with Broadcom Support following the instructions documented in the KB article on creating and managing Broadcom support cases.

Creating and managing Broadcom support cases

Additional Information

If this KB did not help resolve your issue, you can review the following kb for further troubleshooting steps: Troubleshooting NSX Installation Operations