vSphere SDK for Perl Programming Guide
16 VMware, Inc.
Common Options Reference
ThefollowingtablelistsoptionsthatareavailableforallvSphereSDKforPerlscripts.Usetheparameteron
thecommandlineandthevariableortheparameterinconfigurationfiles.
Table 1-3. Options Available for All SDK for Perl Commands
Option and Environment Variable Description
--cacertsfile <certsfile>
-t <certs_file>
VI_CACERTFILE=<cert_file_path>
ESXCLIcommandsonly.
UsedtospecifytheCA(CertificateAuthority)certificatefile,inPEMformat,
toverifytheidentityofthevCenterServersystemorESXisystemtorunthe
commandon.
InvCLI6.0andlater,youcanonlyrunESXCLIcommandsifatrust
relationshipexistsbetween
thehostyouarerunningthecommandonandthe
systemyouaretargetingwiththe--serveroption(ESXihostorvCenter
Serversystem).YoucanestablishthetrustrelationshipbyspecifyingtheCA
certificatefileorbypassinginthethumbprintforeachtargetserver(ESXihost
orvCenterServer
system).
--config <cfg_file_full_path>
VI_CONFIG=<cfg_file_full_path>
Usestheconfigurationfileatthespecified location.
Specifyapaththatisreadablefromthecurrentdirectory.
--credstore <credstore>
VI_CREDSTORE=<credstore>
Nameofacredentialstorefile.Defaultsto
<HOME>/.vmware/credstore/vicredentials.xmlonLinuxand
<APPDATA>/VMware/credstore/vicredentials.xmlonWindows.
CommandsforsettingupthecredentialstoreareincludedinthevSphereSDK
for
Perl,whichisinstalledwithvCLI.ThevSphereSDKforPerlProgramming
Guideexplainshowtomanagethecredentialstore.
--encoding <encoding>
VI_ENCODING=<encoding>
Specifiestheencodingtobeused.Severalencodingsaresupported.
utf8
cp936(SimplifiedChinese)
shftjis(Japanese)
iso-885901(German).
Youcanuse--encodingtospecifytheencodingvCLIshouldmaptowhenit
isrunonaforeignlanguagesystem.
--passthroughauth
VI_PASSTHROUGHAUTH
Ifyouspecifythisoption,thesystemusestheMicrosoftWindowsSecurity
SupportProviderInterface(SSPI)forauthentication.Trustedusersarenot
promptedforausernameand
password.SeetheMicrosoftWebsitefora
detaileddiscussionofSSPI.
ThisoptionissupportedonlyifyouareconnectingtoavCenterServersystem.
--passthroughauthpackage
<package>
VI_PASSTHROUGHAUTHPACKAGE=
<package>
Usethisoptionwith--passthroughauthtospecifyadomain‐level
authenticationprotocoltobeusedbyWindows.Bydefault,SSPIusesthe
Negotiate
protocol,whichmeansthatclientandservertrytonegotiatea
protocolthatbothsupport.
IfthevCenterServersystemtowhichyouareconnectingisconfiguredtouse
aspecificprotocol,youcanspecifythatprotocolusingthisoption.
ThisoptionissupportedonlyifyouarerunningvCLIon
aWindowssystem
andconnectingtoavCenterServersystem.
--password <passwd>
VI_PASSWORD=<passwd>
Usesthespecifiedpassword(usedwith--username)tologintotheserver.
If--serverspecifiesavCenterServersystem,theusernameandpassword
applytothatserver.IfyoucanlogintothevCenterServersystem,you
neednoadditionalauthenticationtoruncommandsontheESXihoststhat
servermanages.
If--serverspecifiesanESXihost,theusernameandpasswordapplyto
thatserver.
Usetheemptystring(' 'onLinuxand“ “onWindows)toindicateno
password.
Ifyoudonotspecifyausernameandpasswordonthecommandline,the
systempromptsyouanddoes
notechoyourinputtothescreen.
--portnumber <number>
VI_PORTNUMBER=<number>
Usesthespecifiedporttoconnecttothesystemspecifiedby--server.Default
is443.