Move-VDisk
This cmdlet moves the specified VDisk objects to the specified datastore. For RDM (RawVDisk), only one VDisk object can be moved at once, and only moving from VMFS to VMFS is supported.
Syntax
Parameters
Required | Parameter Name | Type | Position | Features | Description |
---|---|---|---|---|---|
required
|
Datastore | Datastore | 1 |
|
Specifies the datastore to which you want to move the metadata of the VDisk object. For flat disk, the contents of the disk are also moved to the specified datastore. |
required
|
VDisk | VDisk[] | named |
|
Specifies the VDisk objects you want to move. |
optional | ProgressAction | ActionPreference | named |
|
|
optional | RunAsync | SwitchParameter | named |
|
Indicates that the command returns immediately without waiting for the task to complete. In this mode, the output of the cmdlet is a Task object. For more information about the RunAsync parameter run "help About_RunAsync" in the VMware PowerCLI console. |
optional | Server | VIServer[] | named |
|
Specifies the vCenter Server systems on which you want to run the cmdlet. If no value is provided or $null value is passed to this parameter, the command runs on the default servers. For more information about default servers, see the description of Connect-VIServer. |
optional | StorageFormat | VDiskStorageFormat | named |
|
Specifies the new storage format of the flat VDisk object that is moved. |
Parameters
Required | Parameter Name | Type | Position | Features | Description |
---|---|---|---|---|---|
required
|
Datastore | Datastore | 1 |
|
Specifies the datastore to which you want to move the metadata of the VDisk object. For flat disk, the contents of the disk are also moved to the specified datastore. |
required
|
ScsiLun | ScsiLun | named |
|
Specifies the new backing SCSI LUN for the RDM VDisk object that is moved. |
required
|
VDisk | VDisk[] | named |
|
Specifies the VDisk objects you want to move. |
optional | ProgressAction | ActionPreference | named |
|
|
optional | RunAsync | SwitchParameter | named |
|
Indicates that the command returns immediately without waiting for the task to complete. In this mode, the output of the cmdlet is a Task object. For more information about the RunAsync parameter run "help About_RunAsync" in the VMware PowerCLI console. |
optional | Server | VIServer[] | named |
|
Specifies the vCenter Server systems on which you want to run the cmdlet. If no value is provided or $null value is passed to this parameter, the command runs on the default servers. For more information about default servers, see the description of Connect-VIServer. |
Output
VMware.VimAutomation.ViCore.Types.V1.Storage.VDisk.VDiskExamples
Example 1
Move-VDisk -VDisk $vDisk -Datastore $ds
Moves the flat VDisk object $vDisk to the $ds datastore.
Example 2
Move-VDisk -VDisk $vDisk -ScsiLun $scsiLun -Datastore $ds
Moves the raw VDisk object $vDisk on the $scsiLun SCSI LUN and stores metadata of this object on the $ds datastore.
Related Commands
VDisk
This cmdlet copies the specified VDisk objects to the specified datastore.
This cmdlet lists VDisk objects based on the specified filters.
This cmdlet moves the specified VDisk objects to the specified datastore.
This cmdlet creates a managed VDisk object whose lifecycle is independent of a virtual machine`s lifecycle on the specified datastore.
This cmdlet removes VDisk objects and the associated backings from the datastore.
This cmdlet renames, inflates, or extends the size of the specified VDisk object.