VMware Update Manager cmdlets

Way back beyond the time before PowerCLI was invented there was this app called the Virtual Infrastructure Toolkit, when you installed the VITK if you had Update manager installed you used to be able to install some beta cmdlets which worked with update manager, this was subsequently removed in future versions….. Until Now !

They are back from the dead and in the form of a separate download to the current PowerCLI installable.

Download and install them now !

The first thing you will need to check is what operating system you are installing these on, personally I did not check and ended up with an error when trying to install them on Windows 7 64bit so here is a list of the supported operating systems so you don’t make the same mistake: – OK I may have been using a modified version of PowerCLI – Apparently this does install on Win7 64bit, even if it isn’t in the supported list !

  • Windows Server 2008
  • Windows Vista
  • Windows XP Service Pack 2
  • Windows Server 2003 Service Pack 2

You will also need the following installed:

  • .NET 2.0 SP1
  • Windows PowerShell 1.0 or higher
  • VMware vSphere PowerCLI 4.0 Update 1

After installing, from the PowerCLI prompt we can see a list of the new cmdlets by using the Get-Command cmdlet as below:

Get-Command -PSSnapin VMware.VumAutomation

image

So we can see we have an extra 13 cmdlets, what do these do, well they do all the “Update Manager” type tasks you would expect to do, so now as well as deploying our hosts we can also make sure they are patched to the latest version before adding them into our cluster, all automated of course !

Here is a brief overview of the cmdlets, watch out for some cool one liners soon.

Attach-Baseline

Attaches baselines to the specified Template, VirtualMachine, VMHost, Cluster, Datacenter, Folder, and VApp objects.  Attaching a baseline to a container object such as a folder or datacenter transitively attaches the baseline to all objects in the container.

Detach-Baseline

Detaches baselines from the specified inventory objects.

Download-Patch

Downloads new patches into the Update Manager patch repository from the enabled patch download sources.

Get-Baseline

Retrieves the baselines specified by the provided cmdlet parameters.

Get-Compliance

Retrieve baseline compliance data for the specified object of type Template, VirtualMachine, VMHost, Cluster, Datacenter, Folder, and VApp.

Get-Patch

Retrieves all available patches or those specified by the provided cmdlet parameters.

Get-PatchBaseline

Retrieves all patch baselines or those specified by the provided cmdlet parameters.

New-PatchBaseline

Creates a new patch baseline. Patch baselines can be applied to either hosts or virtual machines. Depending on the patch criteria you select, patch baselines can be either dynamic or static (fixed).

Remediate-Inventory

Remediates an inventory object against the specified baselines.

Remove-Baseline

Deletes the specified baselines from their servers. Before the removal, the baselines are detached from all entities they have beenattached to.

Scan-Inventory

Scans inventory objects for baselines attached to them.

Set-PatchBaseline

Modifies the properties of a patch baseline. You can specify explicitly the patches you want to include in the baseline through the IncludePatch parameter.

Stage-Patch

Initializes staging of patches. Staging allows you to download patches from the Update Manager server to the ESX/ESXi hosts, without applying the patches immediately.

3 thoughts on “VMware Update Manager cmdlets

  1. FG Shepherd

    THANK YOU. I’m not sure why VMware obscures their downloads, but I would have never found this without your post!

  2. Virtu-Al

    Matt, thanks for that, I have ammended my post as I realised afterwards that I may have been using a slightly modified version of PowerCLI.. Doh !

Leave a Reply to Matt

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.