6.5

Table Of Contents
Linking and Unlinking Uplink Adapters with ESXCLI
You can use ESXCLI to link and unlink uplink adapters.
When you create a virtual switch by using esxcli network vswitch standard add, all trac on that virtual
switch is initially conned to that virtual switch. All virtual machines connected to the virtual switch can
talk to each other, but the virtual machines cannot connect to the network or to virtual machines on other
hosts. A virtual machine also cannot connect to virtual machines connected to a dierent virtual switch on
the same host.
Having a virtual switch that is not connected to the network might make sense if you want a group of
virtual machines to be able to communicate with each other, but not with other hosts or with virtual
machines on other hosts. In most cases, you set up the virtual switch to transfer data to external networks by
aaching one or more uplink adapters to the virtual switch.
You can use the following commands to list, add, and remove uplink adapters. When you link by using
ESXCLI, the physical NIC is added as a standby adapter by default. You can then modify the teaming policy
to make the physical NIC active by running the command esxcli network vswitch standard policy
failover set.
n
List uplink adapters.
esxcli <conn_options> network vswitch standard list
The uplink adapters are returned in the Uplink item.
n
Add a new uplink adapter to a virtual switch.
esxcli <conn_options> network vswitch standard uplink add --uplink-name=vmnic15 vswitch-
name=vSwitch0
n
Remove an uplink adapter from a virtual switch.
esxcli <conn_options> network vswitch standard uplink remove --uplink-name=vmnic15 vswitch-
name=vSwitch0
Linking and Unlinking Uplink Adapters with vicfg-vswitch
You can use vicfg-vswitch to link and unlink uplink adapters.
When you create a virtual switch by using vicfg-vswitch --add, all trac on that virtual switch is initially
conned to that virtual switch. All virtual machines connected to the virtual switch can talk to each other,
but the virtual machines cannot connect to the network or to virtual machines on other hosts. A virtual
machine also cannot connect to virtual machines connected to a dierent virtual switch on the same host.
Having a virtual switch that is not connected to the network might make sense if you want a group of
virtual machines to be able to communicate with each other, but not with other hosts or with virtual
machines on other hosts. In most cases, you set up the virtual switch to transfer data to external networks by
aaching one or more uplink adapters to the virtual switch.
You can use the following commands to add and remove uplink adapters.
n
Add a new uplink adapter to a virtual switch.
vicfg-vswitch <conn_options> --link vmnic15 vSwitch0
n
Remove an uplink adapter from a virtual switch.
vicfg-vswitch <conn_options> --unlink vmnic15 vSwitch0
vSphere Command-Line Interface Concepts and Examples
144 VMware, Inc.