Author: William Lam
Twitter: @lamw
Website: http://engineering.ucsb.edu/~duonglt/vmware/
Step 1. Visit the vSphere SDK for Perl Home Page
You will find latest Downloads, Reference Documentation and Community Discussions and links to resources.
Step 2. Become familiar with vSphere SDK for Perl Resources:
Step 3. Explore new ways of managing your vSphere Platform using the remote CLI
- Try some of the esxcfg-* commands using vSphere SDK for Perl scripts
- Additional utilities bundled with vCLI/RCLI installation
Step 4. Develop and create your own scripts and utlities using the vSphere SDK for Perl
- Become familiar vSphere 4.0 API Reference documentation
- Learn how to get started with writing your own Perl script using vSphere SDK for Perl
- I think the easiest way to learn this is to start playing with some of the canned scripts and to make it even easier to have an environment that's all setup for you with both the vCLI and vSphere SDK for Perl, you can download VMware vMA. vMA is a Redhat Enterprise 5 Linux Virtual Appliance to allow administrators and developers to run scripts and agents to manage ESX/ESXi and vCenter Server systems remotely.
Help us improve our document, provide additional useful information and share with a friend.
FAQ
1. What is difference between vSphere API and vSphere SDK for Perl?
Let's define two very important vocabulary words -
Wikipedia defines an
API as:
Source:
http://en.wikipedia.org/wiki/Application_programming_interface
Application programming interface (API) is an interface in computer science that defines the ways by which an application program may request services from libraries and/or operating systems
An API may be:
- Language-dependent; that is, available only in a given programming language, using the syntax and elements of that language to make the API convenient to use in this context.
- Language-independent; that is, written in a way that means it can be called from several programming languages (typically an assembly or C interface). This is a desired feature for a service-style API that is not bound to a given process or system and is available as a remote procedure call.Wikipedia defines SDK as:
Source:
http://en.wikipedia.org/wiki/Sdk
A software development kit (SDK or "devkit") is typically a set of development tools that allows a software engineer to create applications for a certain software package, software framework, hardware platform, computer system, video game console, operating system, or similar platform.
It may be something as simple as an application programming interface (API) in the form of some files to interface to a particular programming language or include sophisticated hardware to communicate with a certain embedded system.Simply put, VMware exposes the VI3/vSphere 4 API as a Web Service API that utilizes (WSDL,SOAP and HTTP) to access server-side objects. From the above
API defintion, an API can be language-indepednent, which is exactly what VMware has done to allow development from the various rich scripting and programming languages such as Perl, PowerCLI, C#, .net and Java. These are the various SDK's or
"bindings" that have been created to allow administrators and developers to write a simple scripts to automate a task or complex applications to monitor, deploy or configure the wide ranges of componets in the VI/vSphere platform.
2. What is difference between RCLI and vCLI?
With the advent of ESXi which is basically ESX without the Service Console, managing and configuring ESXi has slightly changed. VMware wanted to provide some continutity when managing and configuring ESXi and decided to duplicate majority of the esxcfg-* commands and functionality into a set of
"remote" esxcfg-* commands which utilizes the VI/vSphere API and hence RCLI/vCLI was born. The RCLI (Remote Command Line Interface) has been renamed to vCLI (vSphere Command Line Interface) with the release of vSphere.
Here is a table of the new vSphere names from the old VI3 names for the various SDKs/APIs/Toolkits
Great article, seems like the perfect path for mastering the SDK for Perl