Data Object - VirtualMachineRelocateSpec(vim.vm.RelocateSpec)

Property of
PlacementAction, PlacementSpec, StorageMigrationAction, StoragePlacementAction, StoragePlacementSpec, VirtualMachineCloneSpec
Parameter to
CheckRelocate_Task, RelocateVM_Task
Extends
DynamicData
See also
Datastore, Folder, HostSystem, ResourcePool, ServiceLocator, VirtualDeviceConfigSpec, VirtualMachineProfileSpec, VirtualMachineRelocateSpecDiskLocator, VirtualMachineRelocateTransformation

Data Object Description

Specification for moving or copying a virtual machine to a different datastore or host.

Properties

Name Type Description
datastore*ManagedObjectReference
to a Datastore

The datastore where the virtual machine should be located. If not specified, the current datastore is used. If the virtual machine is relocated to a different vCenter service or datacenter the destination datastore must be specified and cannot be unset. Even if the datastore is not changing, the destination datastore will have a different managed object reference in the destination datacenter or vCenter service.
deviceChange*VirtualDeviceConfigSpec[]

An optional list of virtual device specs that allow specifying the new device locations for the relocate operation.

The supported device changes are:

  • For VirtualEthernetCard, it has to be used in device to specify the target network backing.
  • All other specification are ignored.

Since vSphere API 5.5
disk*VirtualMachineRelocateSpecDiskLocator[]

An optional list that allows specifying the datastore location for each virtual disk.
diskMoveType*xsd:string

Manner in which to move the virtual disk to the target datastore. The set of possible values is described in VirtualMachineRelocateDiskMoveOptions.

This property applies to all the disks which the virtual machine has, but can be overridden on a per-disk basis using diskMoveType prior to vSphere API 6.0 or using diskMoveType in vSphere API 6.0 and later.

This property can only be set if deltaDiskBackingsSupported is true.

If left unset then moveAllDiskBackingsAndDisallowSharing is assumed.

Since vSphere API 4.0
folder*ManagedObjectReference
to a Folder

The folder where the virtual machine should be located. If not specified, the root VM folder of the destination datacenter will be used.

Since vSphere API 6.0
host*ManagedObjectReference
to a HostSystem

The target host for the virtual machine. If not specified,
  • if resource pool is not specified, current host is used.
  • if resource pool is specified, and the target pool represents a stand-alone host, the host is used.
  • if resource pool is specified, and the target pool represents a DRS-enabled cluster, a host selected by DRS is used.
  • if resource pool is specified and the target pool represents a cluster without DRS enabled, an InvalidArgument exception be thrown.
  • if the virtual machine is relocated to a different vCenter service, both the destination host has to be specified and cannot be unset.

pool*ManagedObjectReference
to a ResourcePool

The resource pool to which this virtual machine should be attached.
  • For a relocate or clone operation to a virtual machine, if the argument is not supplied, the current resource pool of virtual machine is used.
  • For a clone operation from a template to a virtual machine, this argument is required.
  • If the virtual machine is relocated to a different vCenter service, both the destination host and resource pool have to be specified and cannot be unset.
  • If the virtual machine is relocated to a different datacenter within the vCenter service, the resource pool has to be specified and cannot be unset.

profile*VirtualMachineProfileSpec[]

Storage profile requirement for Virtual Machine's home directory. Profiles are solution specific. Storage Profile Based Management(SPBM) is a vSphere server extension. The API users who want to provision VMs using Storage Profiles, need to interact with SPBM. This is an optional parameter and if user doesn't specify profile, the default behavior will apply.

Since vSphere API 5.5
service*ServiceLocator

The service endpoint of vCenter where the virtual machine should be located. If not specified, the current vCenter service is used. If the virtual machine is relocated to a different vCenter service, the destination host, pool, and datastore parameters have to be explicitly specified by default when the task is submitted.

Since vSphere API 6.0
transform*VirtualMachineRelocateTransformationDeprecated. as of vSphere API 5.0. Use diskBackingInfo instead for disk format conversions. This setting will be ignored for disks with the above property set.

Transformation to perform on the disks. The backend is free to ignore this hint if it is not valid for the current operation. This can be used by clients, for example, to create sparse disks for templates.
See VirtualMachineRelocateTransformation

Properties inherited from DynamicData
None
*Need not be set
Show WSDL type definition