VMkernel interfaces not listed in vSphere UI or esxcli due to stale N-VDS association
search cancel

VMkernel interfaces not listed in vSphere UI or esxcli due to stale N-VDS association

book

Article ID: 401314

calendar_today

Updated On:

Products

VMware vSphere ESXi

Issue/Introduction

  • VMkernel interfaces (e.g., vmk0, vmk1) not visible in vSphere UI or standard CLI commands (esxcfg-vmknic -l, esxcli network ip interface list).
  • Interfaces still appear in esxtop under network stats, indicating active link to physical uplinks.
  • Host remains connected to vCenter with no apparent NSX config errors.
  • esxcfg-vswitch -l shows VMkernel adapters are still mapped to stale N-VDS switch.
  • There was an attempt to migrate ESXi host from N-VDS to C-VDS before and did not succeed.

Environment

VMware NSX

VMware vSphere 

Cause

The VMkernel adapters vmk0 and vmk1 were not successfully migrated from the legacy N-VDS to the new switch. As a result, although they are no longer listed under esxcfg-vmknic -l or esxcli, they still appear bound to uplinks from the stale N-VDS.

Resolution

To resolve the issue of vmk0 and vmk1 being bound to the stale N-VDS, recreate the VMkernel adapters on the correct switch using the following steps:

  1. Resync the transport node configuration with NSX Manager using the API command:
    https://<nsx-manager>/api/v1/transport-nodes/<transport-node-uuid>?action=resync_host_config
    (This helps remove uplinks attached to the N-VDS if the host has successfully completed installation.)
  2. Remove the existing VMkernel adapter
    esxcli network ip interface remove --interface-name=vmk0
  3. Create a new portgroup if needed:
    esxcli network vswitch standard portgroup add --portgroup-name=portgroupname --vswitch-name=vSwitch0
  4. Add the new VMkernel adapter:
    esxcli network ip interface add --portgroup-name=portgroupname
  5. Set the IP address:
    esxcli network ip interface ipv4 set --interface-name=vmkX --ipv4=<IP Address> --netmask=2<subnetmask> --type=static
  6. Tag the interface for management:
    esxcli network ip interface tag add --interface-name=vmk0 --tag=Management
  7. Verify the new adapter exists:
    esxcli network ip interface list

Additional Information