Get-VsanDisk
This cmdlet retrieves the host disks that belong to a vSAN disk group. The cmdlet retrieves both SSD and HDD types of disks.
Syntax
[-CanonicalName
<String[]>]
[-Server <VIServer[]>]
[-VsanDiskGroup <VsanDiskGroup[]>]
[CommonParameters]
[-Server <VIServer[]>]
[-VsanDiskGroup <VsanDiskGroup[]>]
[CommonParameters]
Parameters
Required | Parameter Name | Type | Position | Features | Description |
---|---|---|---|---|---|
optional |
|
String[] | named |
|
Specifies the canonical names of the retrieved disks. | optional |
|
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 |
|
VsanDiskGroup[] | named |
|
Specifies the vSAN disk groups that the disks are part of. |
-VMHost
<VMHost[]>
[-CanonicalName <String[]>]
[-Server <VIServer[]>]
[CommonParameters]
[-CanonicalName <String[]>]
[-Server <VIServer[]>]
[CommonParameters]
Parameters
Required | Parameter Name | Type | Position | Features | Description |
---|---|---|---|---|---|
required |
|
VMHost[] | named |
|
Specifies the hosts that the retrieved disks are attached to. | optional |
|
String[] | named |
|
Specifies the canonical names of the retrieved disks. | optional |
|
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. |
-Id
<String[]>
[-Server <VIServer[]>]
[CommonParameters]
[-Server <VIServer[]>]
[CommonParameters]
Parameters
Required | Parameter Name | Type | Position | Features | Description |
---|---|---|---|---|---|
required |
|
String[] | named |
|
Specifies the IDs of the retrieved disks. Note: When a list of values is specified for the Id parameter, the returned objects would have an ID that matches exactly one of the string values in that list. | optional |
|
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.Storage.Types.V1.Vsan.VsanDisk
Examples
Example 1
Get-VsanDisk -CanonicalName "DiskCanonicalName" -VMHost $vmHost
Retrieves all vSAN disks with canonical name "DiskCanonicalName" from the $vmHost virtual machine host.
Example 2
Get-VsanDisk -CanonicalName "DiskCanonicalName" -VsanDiskGroup $vsanDiskGroup
Retrieves all vSAN disks with canonical name "DiskCanonicalName" from the $vsanDiskGroup vSAN disk group.
Example 3
Get-VsanDisk -Id "MyVsanDiskId"
Retrieves the vSAN disk with ID "MyVsanDiskId".
Related Commands
VsanDisk
This cmdlet retrieves the host disks that belong to a vSAN disk group.
This cmdlet removes the specified hard disks from the specified vSAN disk group.
This cmdlet adds a host SCSI disk to a vSAN disk group.
VsanDiskGroup
This cmdlet retrieves vSAN disk groups.
This cmdlet removes vSAN disk groups.
This cmdlet creates a new vSAN disk group backed by the specified devices.