Get-VsanDiskGroup Command | Vmware PowerCLI Reference

Get-VsanDiskGroup

This cmdlet retrieves vSAN disk groups in a cluster or a host, by ID, name, or the canonical name of a disk within the disk group.

Syntax

Get-VsanDiskGroup
-VMHost < VMHost[] >
[-DiskCanonicalName < String[] > ]
[-ProgressAction < ActionPreference > ]
[-Server < VIServer[] > ]
[CommonParameters]

Parameters

Required Parameter Name Type Position Features Description
required
VMHost VMHost[] named
  • pipeline
  • wildcards
Specifies the hosts that the retrieved groups are on.
optional DiskCanonicalName String[] named
Specifies the canonical names of disks that are part of the retrieved groups.
optional ProgressAction ActionPreference named
optional Server VIServer[] named
  • wildcards
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.
Get-VsanDiskGroup
-Id < String[] >
[-ProgressAction < ActionPreference > ]
[-Server < VIServer[] > ]
[CommonParameters]

Parameters

Required Parameter Name Type Position Features Description
required
Id String[] named
Specifies the IDs of disks that are part of the retrieved groups. 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 ProgressAction ActionPreference named
optional Server VIServer[] named
  • wildcards
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.
Get-VsanDiskGroup
[-Cluster < Cluster[] > ]
[-Name < String[] > ]
[-ProgressAction < ActionPreference > ]
[-Server < VIServer[] > ]
[CommonParameters]

Parameters

Required Parameter Name Type Position Features Description
optional Cluster Cluster[] named
  • pipeline
  • wildcards
Specifies the clusters that the retrieved groups are on.
optional Name String[] named
  • wildcards
Specifies the name of the vSAN disk group you want to retrieve.
optional ProgressAction ActionPreference named
optional Server VIServer[] named
  • wildcards
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.VsanDiskGroup

Examples

Example 1

Get-VsanDiskGroup -DiskCanonicalName "DiskCanonicalName" -VMHost $vmHost

Retrieves all vSAN disk groups that contain a disk with canonical name "DiskCanonicalName" from the $vmHost virtual machine host.

Example 2

Get-VsanDiskGroup -Name "MyVsanDiskGroup" -Cluster $cluster

Retrieves all vSAN disk groups named "MyVsanDiskGroup" from the $cluster cluster.

Example 3

Get-VsanDiskGroup -Id "MyVsanDiskGroupId"

Retrieves the vSAN disk group with ID "MyVsanDiskGroupId".

Related Commands

VsanDisk

This cmdlet retrieves the host disks that belong to a vSAN disk group.

This cmdlet adds a host SCSI disk to a vSAN disk group.

This cmdlet removes the specified hard disks from the specified vSAN disk group.

VsanDiskGroup

This cmdlet retrieves vSAN disk groups.

This cmdlet creates a new vSAN disk group backed by the specified devices.

This cmdlet removes vSAN disk groups.