O'Reilly logo

Windows PowerShell® 2.0 Bible by Tome Tanasovski, Mark E. Schill, Karl Mitschke, Thomas Lee

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

CHAPTER 23

Managing VMware vSphere PowerCLI

IN THIS CHAPTER

Using PowerCLI

Working with ESX hosts

Scripting against virtual machines

Managing vCenter

VMware and Windows PowerShell both received a great boom in support after VMware released its VI toolkit in 2008. This toolkit was a snap-in built on top of Windows PowerShell V1, and as the product matured, it became the standard scripting language for VMware. Though VMware also had a Perl toolkit and an SDK, the Windows PowerShell implementation enabled some administrators to become active scripters almost overnight. VMware had already invested heavily in Windows as its management tier with vCenter; Windows PowerShell has many syntactical elements that make it easy for a Unix administrator or Perl scripter to adopt the language quickly. Add those two facts together, and it is no surprise that Windows PowerShell quickly became the standard for scripting against VMware's products.

Installing and Using the Cmdlets

The latest implementation of the cmdlets used to manage VMware is known as vSphere PowerCLI. At the time of writing, PowerCLI is in Version 4.1.1.

Installing PowerCLI

PowerCLI can be installed on most versions of Windows, and it can be used with any version of Windows PowerShell. You can use PowerCLI to manage ESX from Version 3.0.3 and higher (including ESXi), but it requires these hosts to be patched to appropriate versions. It also requires vCenter 2.5 Update 6 if you want to use the cmdlets with vCenter.

To install ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required