Lead Image © Rgbspace, Fotolia.com

Lead Image © Rgbspace, Fotolia.com

New Features in PowerCLI 6.0 R3

Easy Livin'

Article from ADMIN 37/2017
By , By
PowerCLI in the current version 6 R3 supports access to nearly all VMware data center and cloud products with around 500 cmdlets, including numerous additional features, APIs, and interfaces. In this article, we show you the most important innovations.

The initial version 6 of PowerCLI, the Windows PowerShell interface for managing VMware vSphere, appeared in March 2015 to coincide with the release of vSphere 6.0. In mid-September 2015, release 2 followed. Because VMware has finalized some important PowerCLI 6 features in R3, we only look at the R3 version in this article. If you are still using PowerCLI R1 or R2, you might want to upgrade to R3 to take advantage of all the new features and to future-proof your scripts from the outset.

If your vSphere landscape is still based on version 5.5 or earlier, you can still use PowerCLI 6. Although some innovations are only relevant for vSphere 6, such as support for the new virtual machine hardware version 11 in conjunction with the New-VM or Set-VM cmdlets, the shell is nevertheless 100 percent downward compatible with all version 5 products. An update to PowerCLI 6 is also worthwhile in the context of a vSphere 5.x environment, for example, to benefit from the improved PowerCLI architecture. Scripts that explicitly address the new 6.0 features will not work in this case.

Modules Instead of Snap-Ins

The PowerCLI structure has undergone a rigorous adaptation to the PowerShell design specifications. Almost all the essential functions, for example, are now implemented as modules, and their paths are also properly registered in PowerShell ($env:PSModulePath). The only exceptions are AutoDeploy and ImageBuilder, whose cmdlets are still bundled in PowerShell snap-ins, as well as the core cmdlets of vSphere automation, which are always implicitly loaded whatever else you do.

The architectural changes mean that existing scripts that explicitly look for snap-ins may no longer find them, so you might want to adjust your scripts to search for PowerShell modules instead of snap-ins.

Fixed Bug in the Installer

R3 fixes an annoying bug in the installer of former PowerCLI versions, in which, without explicitly stating a path, modules were only visible to the user who originally installed PowerCLI. This bug is fixed now, which alone is a good reason to upgrade to R3. VMware also has unified the installer, with only a single download for all components. The user can now select or deselect three categories during installation: vSphere, vCloud, and Update Manager, which is also supported by a module in PowerCLI 6 R3.

Incidentally, the PowerShell interfaces for managing Horizon View and Mirage are no longer part of the PowerCLI distribution in version 6.0. Although the cmdlets largely follow the same object model, they are only available when you install View or Mirage.

Incidentally, the changes to reflect Microsoft's increasingly strict design guidelines are noticeable in the system requirements for PowerCLI 6; you need at least PowerShell 4.0 and .NET Framework 4.5 on your system.

PowerCLI as a Community Product

Releasing the first version of PowerCLI – at that time, still under the name VI Toolkit 1.0 with around 120 cmdlets – in July 2008 was a risky business, because PowerShell at the time was not nearly as powerful and enjoyed nothing like today's popularity among Windows administrators. Thanks to the established Perl-based RemoteCLI, thousands of scripts for managing the VMware infrastructure (VI), from which vSphere (version 4) later emerged, already existed.

PowerCLI was a complete success, primarily thanks to partners and customers, who adopted the new versions into their own scripting environments, tested them thoroughly, and contributed feedback. Part of this feedback is now institutionalized in the form of PowerCLI 6; for the first time, the shell asks the user on first launching the newly installed PowerCLI environment if they would like to participate in the Customer Experience Improvement Program (CEIP). If you select Join , PowerCLI attempts to transmit anonymized data on the use of cmdlets – and the issues that arise – to VMware. Of course, you can change your initial choices later with

>Set-PowerCLIConfiguration -ParticipateInCEIP <$set>

where substituting $true for <$set> indicates participation and $false indicates nonparticipation.

If the computer on which the user is working with PowerCLI Shell has Internet access, the Get-PowerCLICommunity command launches the default browser, pointing to the home page of the VMware PowerCLI community.

Buy this article as PDF

Express-Checkout as PDF
Price $2.95
(incl. VAT)

Buy ADMIN Magazine

SINGLE ISSUES
 
SUBSCRIPTIONS
 
TABLET & SMARTPHONE APPS
Get it on Google Play

US / Canada

Get it on Google Play

UK / Australia

Related content

comments powered by Disqus
Subscribe to our ADMIN Newsletters
Subscribe to our Linux Newsletters
Find Linux and Open Source Jobs



Support Our Work

ADMIN content is made possible with support from readers like you. Please consider contributing when you've found an article to be beneficial.

Learn More”>
	</a>

<hr>		    
			</div>
		    		</div>

		<div class=