Remove Management Interface (vmk0) from pre-existing Distributed Virtual Switch (VDS) and attached to Port Group on new Virtual Switch
esxcfg-vswitch -l
esxcli network vswitch dvs vmware list
esxcfg-vswitch -Q vmnic0 -V ${DVS_ID_FROM_ABOVE} ${DVS_NAME}
esxcli network ip interface remove --interface-name=vmk0
esxcfg-vswitch -l
esxcfg-vswitch -a vSwitch1
esxcfg-vswitch -l
esxcfg-vswitch -L vmnic0 vSwitch1
esxcli network nic list
esxcfg-vswitch -l
Create the Management port group
esxcfg-vswitch -A mgmt vSwitch1
esxcfg-vswitch -l
Create vmk0 and assign to the Management port group
esxcli network ip interface list
esxcli network ip interface add --interface-name=vmk0 --portgroup-name=mgmt
esxcli network ip interface list
esxcli network ip interface ipv4 set \
--interface-name=vmk0 \
--ipv4=10.10.10.222 \
--netmask=255.255.255.0 \
--type=static
esxcfg-route -a default 10.10.10.1
Tag vmk0 for use as the Management interface
esxcli network ip interface tag add -i vmk0 -t Management