February 2014
Intermediate to advanced
374 pages
8h 12m
English
To move a virtual machine to another folder, host, cluster, resource pool, or datastore, you can use the Move-VM cmdlet. This cmdlet has the following syntax:
Move-VM [-AdvancedOption <AdvancedOption[]>] [[-Destination] <VIContainer>] [-Datastore <StorageResource>] [-DiskStorageFormat <VirtualDiskStorageFormat>] [-RunAsync] [-VM] <VirtualMachine[]> [-Server <VIServer[]>] [-WhatIf] [-Confirm] [<CommonParameters>]
In the first example, we will move the VM2 virtual machine to host 192.168.0.133:
PowerCLI C:\> Get-VM -Name VM2 | Move-VM -Destination 192.168.0.133
The output to the preceding command is as follows:
Name PowerState Num CPUs MemoryGB ---- ---------- ...
Read now
Unlock full access