Upgrading virtual machine compatibility

To upgrade virtual machine compatibility, you can use the Set-VM cmdlet that you have seen before. You have to use the –Version parameter and specify the new compatibility version as a parameter value. At the time of writing this book, the only valid versions are v4, v7, v8, v9, and v10. Virtual machines compatible with Version 10 can no longer be edited with the vSphere C# Client. You will have to use the vSphere Web Client or PowerCLI to edit the configuration for these virtual machines.

The following example will upgrade the VM7 virtual machine to compatibility Version 10:

PowerCLI C:\> Get-VM -Name VM7 | `
>>  Set-VM -Version V10 -Confirm:$false
>>

The output to the preceding command is as follows:

Name ...

Get Learning PowerCLI now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.