vSphere SDK for Perl Programming Guide - Documentation - VMware
vSphere SDK for Perl Programming Guide - Documentation - VMware
vSphere SDK for Perl Programming Guide - Documentation - VMware
You also want an ePaper? Increase the reach of your titles
YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.
login<br />
Parameters<br />
Parameter Description<br />
Returns<br />
Returns the <strong>vSphere</strong> object instance.<br />
Example<br />
Chapter 4 <strong>vSphere</strong> <strong>SDK</strong> <strong>for</strong> <strong>Perl</strong> Subroutine Reference<br />
service_url URL of the server to which the client connects (optional if using session_file).<br />
session_file Full path and filename <strong>for</strong> a session file returned by save_session(). You must specify either<br />
session_file or session_id. You must pass in the filename as a hash.<br />
session_id Session ID returned by get_session_id(). You must specify either session_file or<br />
session_id.<br />
To load a session using a session file: load_session(session_file => $filename);<br />
To load a session using a session ID: load_session(service_url => $url, session_id =><br />
$sessionid);<br />
Establishes a session with the Web service running on the vCenter Server or ESX/ESXi system using the user<br />
name and password credentials provided using the command‐line, environment variables, or configuration<br />
file.<br />
NOTE In most cases, you use Util::connect() instead to establish a connection.<br />
Parameters<br />
Parameter Description<br />
service_url URL of the server to which the client connects.<br />
user_name User account on the ESX/ESXi or vCenter Server system.<br />
password Password <strong>for</strong> the user account.<br />
Returns<br />
Returns the <strong>vSphere</strong> object instance.<br />
logout<br />
Disconnects the client from the server and closes the connection to the Web service. Use this subroutine if you<br />
connected using Vim::login(). Otherwise, use Util::disconnect().<br />
Parameters<br />
No parameters.<br />
Returns<br />
Returns nothing.<br />
<strong>VMware</strong>, Inc. 49