Information Technology Reference
In-Depth Information
highly recommend the topic VMware vSphere PowerCLI Reference (Wiley, 2011). It contains a
wealth of information and detailed explanations of PowerCLI capabilities.
Using vCLI from vSphere Management Assistant
VMware vSphere 5 saw the retirement of VMware ESX and the traditional Linux-based Service
Console. This meant that a lot of vSphere administrators and organizations needed to adapt to
not having a Linux environment available on each host. Since administrators still require this
type of functionality, VMware released the vSphere CLI (vCLI). The vCLI is built on the vSphere
SDK for Perl and implements the familiar console commands from the old ESX Service Console
onto Windows and Linux servers. This improves both security and scalability by providing a
single managed point of contact for your environment.
VMware took this a step further in introducing the vSphere Management Assistant, most
commonly referred to by its acronym, vMA. This 64-bit virtual appliance can be quickly down-
loaded and implemented into your vSphere environment and comes preloaded with vCLI and
the vSphere SDK for Perl. This centrally provides vSphere administrators with the tools they
were accustomed to in the service console prior to vSphere 5.0. The vMA can manage vSphere
5.0, 5.1, and vSphere 5.5 environments. Additional features are available in the vMA to make
managing multiple ESXi hosts easier. We'll go over a few of those features in the following sec-
tions, but let's start with what is new with vCLI and vMA.
What's New in vCLI and vMA for vSphere 5.5
The release of vSphere 5.5 means the inclusion of new features in the vSphere Command Line
Interface (vCLI) and the vSphere Management Assistant (vMA). Most notable is the inclusion
of commands for managing VSAN coni gurations, coredump, and vFlash. Check out the vCLI
release notes for a full listing of new capabilities. The vMA has not changed signii cantly with
this release outside of the updates to vCLI and SDK for Perl.
Getting Started with vCLI
Whether you are running vCLI from your own deployed server or the vMA, there are a great
deal of tasks that you can automate. In this section we'll go over a few examples of using
the vCLI.
One common use case for the vCLI that we've used in the past is the manipulation of
vSwitches in vSphere. Typically this may be necessary for troubleshooting network connections.
Fortunately, the vCLI allows you to do a great deal for reporting and coni guring networking on
your ESXi hosts. For example, to add a vSwitch to a host with the vCLI, you use the exact same
syntax as previously, with an added option to specify the host to which you need to connect:
esxcfg-vswitch --server <Hostname> --list
Alternatively, you can use the newer vCLI naming convention where the commands use the
vicfg- prei x in place of esxcfg-. The esxcfg- prei x is kept for backward compatibility but
will be phased out over time. Therefore, you can currently use either format. We suggest you
begin adopting vicfg- as soon as you can and update existing scripts accordingly.
 
Search WWH ::




Custom Search