Standard or Distributed Switch changes fail with the error "A specified parameter was not correct"
search cancel

Standard or Distributed Switch changes fail with the error "A specified parameter was not correct"

book

Article ID: 339882

calendar_today

Updated On:

Products

VMware vSphere ESXi

Issue/Introduction

Symptoms:
  • In vCenter, operations to modify portgroups, add/remove pNics, or modify Teaming policies on a vSS or vDS fail with the error: 
 "A specified parameter was not correct"
 
  • Unable to modify or add a gateway of a TCP/IP Stack.
  • "Invalid NIC" errors are seen in hostd.log: 
2022-04-12T04:28:47.417Z info hostd[2099563] [Originator@6876 sub=Vimsvc.TaskManager opID=kxaqfuni-78739569-auto-1avnwu-h5:73869704-7e-e5-cb5c user=vpxuser:Domain\Username] Task Created : haTask-ha-host-vim.host.NetworkSystem.invokeHostTransactionCall-3917783281
2022-04-12T04:28:47.418Z info hostd[2099426] [Originator@6876 sub=Hostsvc opID=kxaqfuni-78739569-auto-1avnwu-h5:73869704-7e-e5-cb5c user=vpxuser:Domain\Username] UpdateNetwork with Config: (vim.host.NetworkConfig) {
-->    proxySwitch = (vim.host.HostProxySwitch.Config) [
-->       (vim.host.HostProxySwitch.Config) {
-->          changeOperation = "edit",

2022-04-12T04:28:47.440Z info hostd[2099426] [Originator@6876 sub=Hostsvc opID=kxaqfuni-78739569-auto-1avnwu-h5:73869704-7e-e5-cb5c user=vpxuser:Domain\Username] Invalid NIC order: one of more PNIC specified are not uplinked to vswitch.
2022-04-12T04:28:47.440Z info hostd[2099426] [Originator@6876 sub=Hostsvc opID=kxaqfuni-78739569-auto-1avnwu-h5:73869704-7e-e5-cb5c user=vpxuser:Domain\Username] Invalid NIC teaming policy: invalid NIC order specified.
2022-04-12T04:28:47.440Z info hostd[2099426] [Originator@6876 sub=Hostsvc opID=kxaqfuni-78739569-auto-1avnwu-h5:73869704-7e-e5-cb5c user=vpxuser:Domain\Username] Invalid network policy: invalid NIC teaming policy.
2022-04-12T04:28:47.440Z info hostd[2099426] [Originator@6876 sub=Hostsvc.NetworkVmkSimulator opID=kxaqfuni-78739569-auto-1avnwu-h5:73869704-7e-e5-cb5c user=vpxuser:Domain\Username] Cannot set policy for vswitch [vSwitchUSB0], network policy is invalid: (vim.host.NetworkPolicy) {
 
  • In the vmware-vimdump output, you might see "bridge = <unset>"
                     (vim.host.VirtualSwitch) {
                        dynamicType = <unset>,
                        dynamicProperty = (vmodl.DynamicProperty) [],
                        name = 'vSwitchUSB0',
                        key = 'key-vim.host.VirtualSwitch-vSwitchUSB0',
                        numPorts = 4350,
                        numPortsAvailable = 4327,
                        mtu = 1500,
                        portgroup = (Link) [
                           'key-vim.host.PortGroup-IMM_Network0'
                        ],
                        pnic = (Link) [],
                        spec = (vim.host.VirtualSwitch.Specification) {
                           dynamicType = <unset>,
                           dynamicProperty = (vmodl.DynamicProperty) [],
                           numPorts = 128,
                           bridge = <unset>,   <-------- Here

Environment

VMware vSphere ESXi 7.x
VMware ESXi 6.5.x
VMware ESXi 6.7.x

Cause

If NetworkSystem.invokeHostTransactionCall is called to make changes to a vSS or vDS while there is a configuration issue with vSwitchUSB0, the change operation will fail.  In this particular case, vusb0 did not exist on bootup.
 
Syslog.log: 
2022-04-12T03:19:20.548Z jumpstart[2097601]: VirtualSwitch: Unable to restore uplink vusb0  of virtual swtich vSwitchUSB0. Reason was Unable to find mapping for vusb0:
2022-04-12T03:19:20.549Z jumpstart[2097601]: PortGroup: NIC vusb0 does not exist
2022-04-12T03:19:20.549Z jumpstart[2097601]: PortGroup: NIC vusb0 does not exist
2022-04-12T03:19:20.550Z jumpstart[2097601]: PortGroup: Unable to find mapping for vusb0
2022-04-12T03:19:20.550Z jumpstart[2097601]: PortGroup: Not a valid pnic:  for teaming on portgroup: IMM_Network0
 
Vobd.log: 
2022-04-12T03:20:13.731Z: [UserLevelCorrelator] 91443881us: [vob.user.host.boot] Host has booted.

Resolution

  • Try re-adding vusb0 to vSwitchUSB0: 
 
esxcli network vswitch standard uplink add --uplink-name="vusb0" --vswitch-name="vSwitchUSB0" 
 
  • In similar cases, toggling the vSwitchUSB0/vusb0 Teaming policy from Active to Standby (or vice versa) has been known to work. 
  • Remove vSwitchUSB0.  If it repopulates, please contact your hardware vendor on how to properly disable the vUSB device. 
 
esxcli network vswitch standard remove --vswitch-name=vSwitchUSB0