0
for no VLAN).[root@server root]# esxcfg-vswitch -l
Switch Name Num Ports Used Ports Configured Ports Uplinks
vSwitch0 32 4 32 vmnic0
PortGroup Name Internal ID VLAN ID Used Ports Uplinks
VM Network 0 portgroup1 0 0 vmnic0
Service Console portgroup0 0 1 vmnic0
Switch Name Num Ports Used Ports Configured Ports Uplinks
vSwitch1 64 2 64 vmnic1
PortGroup Name Internal ID VLAN ID Used Ports Uplinks
VM Network 1 portgroup19 0 0 vmnic1
[root@server root]# esxcfg-vswitch -p "portgroup_name" -v VLAN_IDvirtual_switch_name
portgroup_name
is the name of your portgroup, and virtual_switch_name
is the name of your virtual switch.10
to VM Network 1
(which resides on vSwitch1
), you must run the command:[root@server root]# esxcfg-vswitch -p "VM Network 1" -v 10 vSwitch1
[root@server root]# esxcfg-vswitch -l
Switch Name Num Ports Used Ports Configured Ports Uplinks
vSwitch1 64 2 64 vmnic1
PortGroup Name Internal ID VLAN ID Used Ports Uplinks
VM Network 1 portgroup19 10 0 vmnic1
esxcfg-vswitch -U vmnic vSwitch
esxcfg-vswitch -L vmnic vSwitch