Search

Method migrateVM_Task(VcResourcePool pool, VcHostSystem host, VcVirtualMachineMovePriority priority, VcVirtualMachinePowerState state)

Migrates a virtual machine's execution to a specific resource pool or host.

Requires Resource.HotMigrate privilege if the virtual machine is powered on or Resource.ColdMigrate privilege if the virtual machine is powered off or suspended.

Returns

VcTask

Arguments

Name Type Description
pool VcResourcePool The target resource pool for the virtual machine. If the pool parameter is left unset, the virtual machine's current pool is used as the target pool.
host VcHostSystem The target host to which the virtual machine is intended to migrate. The host parameter may be left unset if the compute resource associated with the target pool represents a stand-alone host or a DRS-enabled cluster. In the former case the stand-alone host is used as the target host. In the latter case, the DRS system selects an appropriate target host from the cluster.
priority VcVirtualMachineMovePriority The task priority (@see vim.VirtualMachine.MovePriority).
state VcVirtualMachinePowerState If specified, the virtual machine migrates only if its state matches the specified state.