6.0

Table Of Contents
Getting Started with vSphere Command-Line Interfaces
124 VMware, Inc.
Managing Uplink Adapters with vicfg-nics
Thefollowingexampleworkflowlistsanuplinkadaptersproperties,changestheduplexandspeed,andsets
theuplinktoautonegotiateitsspeedandduplexsettings.Specifyoneoftheoptionslistedin“Connection
OptionsforvCLIHostManagementCommands”onpage 18inplaceof<conn_options>.
To manipulate uplink adapter setup
1Listsettings.
vicfg-nics <conn_options> -l
Liststheuplinksinthesystem,theircurrentandconfiguredspeed,andtheirduplexsetting.
2Setthesettingsforvmnic0tofullandthespeedto100.
vicfg-nics <conn_options> -d full -s 100 vmnic0
3Setvmnic2toautonegotiateitsspeedandduplexsettings.
vicfg-nics <conn_options> -a vmnic2
Linking and Unlinking Uplink Adapters with ESXCLI
Whenyoucreateavirtualswitchusingesxcli network vswitch standard add,alltrafficonthatvirtual
switchisinitiallyconfinedtothatvirtualswitch.Allvirtualmachinesconnectedtothevirtualswitchcantalk
toeachother,butthevirtualmachinescannotconnecttothenetworkortovirtualmachinesonotherhosts.
A
virtualmachinealsocannotconnecttovirtualmachinesconnectedtoadifferentvirtualswitchonthesame
host.
Havingavirtualswitchthatisnotconnectedtothenetworkmightmakesenseifyouwantagroupofvirtual
machinestobeabletocommunicatewitheachother,butnot
withotherhostsorwithvirtualmachineson
otherhosts.Inmostcases,yousetupthevirtualswitchtotransferdatatoexternalnetworksbyattachingone
ormoreuplinkadapterstothevirtualswitch.
Youcanusethefollowingcommandstolist,add,andremoveuplinkadapters.When
youlinkusingESXCLI,
thephysicalNICisaddedasastandbyadapterbydefault.Youcanthenmodifytheteamingpolicytomake
thephysicalNICactivebyrunningthecommandesxcli network vswitch standard policy failover
set.
Listuplinkadapters.
esxcli <conn_options> network vswitch standard list
Theuplinkadaptersarereturned intheUplinkitem.
Addanewuplinkadaptertoavirtualswitch.
esxcli <conn_options> network vswitch standard uplink add --uplink-name=vmnic15
vswitch-name=vSwitch0
Removeanuplinkadapterfromavirtualswitch.
esxcli <conn_options> network vswitch standard uplink remove --uplink-name=vmnic15
vswitch-name=vSwitch0
Linking and Unlinking Uplink Adapters with vicfg-vswitch
Whenyoucreateavirtualswitchusingvicfg-vswitch--add,alltrafficonthatvirtualswitchisinitially
confinedtothatvirtualswitch.Allvirtualmachinesconnectedtothevirtualswitchcantalktoeachother,but
thevirtualmachinescannotconnecttothenetworkortovirtualmachinesonother
hosts.Avirtualmachine
alsocannotconnecttovirtualmachinesconnectedtoadifferentvirtualswitchonthesamehost.
Havingavirtualswitchthatisnotconnectedtothenetworkmightmakesenseifyouwantagroupofvirtual
machinestobeabletocommunicatewitheachother,but
notwithotherhostsorwithvirtualmachineson
otherhosts.Inmostcases,yousetupthevirtualswitchtotransferdatatoexternalnetworksbyattachingone
ormoreuplinkadapterstothevirtualswitch.
Youcanusethefollowingcommandstoaddandremoveuplinkadapters: