Get-PhysicalDisk

Gets a list of all PhysicalDisk objects visible across any available Storage Management Providers, or optionally a filtered list.

Syntax

Get-PhysicalDisk
   [-UniqueId <String[]>]
   [-Usage <Usage[]>]
   [-Description <String[]>]
   [-Manufacturer <String[]>]
   [-Model <String[]>]
   [-CanPool <Boolean[]>]
   [-HealthStatus <HealthStatus[]>]
   [-CimSession <CimSession[]>]
   [-ThrottleLimit <Int32>]
   [-AsJob]
   [<CommonParameters>]
Get-PhysicalDisk
   [-ObjectId <String[]>]
   [-Usage <Usage[]>]
   [-Description <String[]>]
   [-Manufacturer <String[]>]
   [-Model <String[]>]
   [-CanPool <Boolean[]>]
   [-HealthStatus <HealthStatus[]>]
   [-CimSession <CimSession[]>]
   [-ThrottleLimit <Int32>]
   [-AsJob]
   [<CommonParameters>]
Get-PhysicalDisk
   [[-FriendlyName] <String[]>]
   [-Usage <Usage[]>]
   [-Description <String[]>]
   [-Manufacturer <String[]>]
   [-Model <String[]>]
   [-CanPool <Boolean[]>]
   [-HealthStatus <HealthStatus[]>]
   [-CimSession <CimSession[]>]
   [-ThrottleLimit <Int32>]
   [-AsJob]
   [<CommonParameters>]
Get-PhysicalDisk
   [-Usage <Usage[]>]
   [-Description <String[]>]
   [-Manufacturer <String[]>]
   [-Model <String[]>]
   [-CanPool <Boolean[]>]
   [-HealthStatus <HealthStatus[]>]
   [-VirtualDisk <CimInstance>]
   [-VirtualRangeMin <UInt64>]
   [-VirtualRangeMax <UInt64>]
   [-HasAllocations <Boolean>]
   [-SelectedForUse <Boolean>]
   [-CimSession <CimSession[]>]
   [-ThrottleLimit <Int32>]
   [-AsJob]
   [<CommonParameters>]
Get-PhysicalDisk
   [-Usage <Usage[]>]
   [-Description <String[]>]
   [-Manufacturer <String[]>]
   [-Model <String[]>]
   [-CanPool <Boolean[]>]
   [-HealthStatus <HealthStatus[]>]
   [-StoragePool <CimInstance>]
   [-CimSession <CimSession[]>]
   [-ThrottleLimit <Int32>]
   [-AsJob]
   [<CommonParameters>]
Get-PhysicalDisk
   [-Usage <Usage[]>]
   [-Description <String[]>]
   [-Manufacturer <String[]>]
   [-Model <String[]>]
   [-CanPool <Boolean[]>]
   [-HealthStatus <HealthStatus[]>]
   [-StorageNode <CimInstance>]
   [-CimSession <CimSession[]>]
   [-ThrottleLimit <Int32>]
   [-AsJob]
   [<CommonParameters>]
Get-PhysicalDisk
   [-Usage <Usage[]>]
   [-Description <String[]>]
   [-Manufacturer <String[]>]
   [-Model <String[]>]
   [-CanPool <Boolean[]>]
   [-HealthStatus <HealthStatus[]>]
   [-StorageEnclosure <CimInstance>]
   [-CimSession <CimSession[]>]
   [-ThrottleLimit <Int32>]
   [-AsJob]
   [<CommonParameters>]
Get-PhysicalDisk
   [-Usage <Usage[]>]
   [-Description <String[]>]
   [-Manufacturer <String[]>]
   [-Model <String[]>]
   [-CanPool <Boolean[]>]
   [-HealthStatus <HealthStatus[]>]
   [-StorageSubSystem <CimInstance>]
   [-CimSession <CimSession[]>]
   [-ThrottleLimit <Int32>]
   [-AsJob]
   [<CommonParameters>]

Description

The Get-PhysicalDisk cmdlet gets a list of all PhysicalDisk objects visible across any available Storage Management Providers, or optionally a filtered list of disks.

Examples

Example 1: Getting all physical disks

PS C:\> Get-PhysicalDisk
FriendlyName        CanPool            OperationalStatus   HealthStatus        Usage                              Size 
------------        --------            -----------------   ------------        -----                              ---- 
PhysicalDisk4       False               OK                  Healthy             Data Store                        25 GB

This example returns an array of all PhysicalDisk objects present in the computer. A storage management provider is required to manage physical disks.

Example 2: Getting all physical disks eligible for adding to a storage pool

PS C:\>Get-PhysicalDisk -CanPool $True

This example returns an array of PhysicalDisk objects that are available for adding to a storage pool (they are in a primordial pool).

Optional Parameters

-AsJob

ps_cimcommon_asjob

Type:SwitchParameter
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-CanPool

Gets physical disks that are available for use in a storage pool.

Type:Boolean[]
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-CimSession

Runs the cmdlet in a remote session or on a remote computer. Enter a computer name or a session object, such as the output of a New-CimSessionhttp://go.microsoft.com/fwlink/p/?LinkId=227967 or Get-CimSessionhttp://go.microsoft.com/fwlink/p/?LinkId=227966 cmdlet. The default is the current session on the local computer.

Type:CimSession[]
Aliases:Session
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Description

Gets the physical disks that contain the specified description. Enter a description, or use wildcard characters to enter a description pattern.

Type:String[]
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-FriendlyName

Gets the physical disk with the specified friendly name. Enter a friendly name, or use wildcard characters to enter a name pattern.

Type:String[]
Position:0
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False
-HasAllocations

Indicates whether the cmdlet gets a list of physical disks that host the extents of the virtual disk that you specify by using the VirtualDisk parameter.

Type:Boolean
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-HealthStatus

Gets only physical disks in the specified state. Valid values are Healthy, Unhealthy, Unknown, or Warning.

Type:HealthStatus[]
Accepted values:Healthy, Warning, Unhealthy, Unknown
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Manufacturer

Gets the physical disks with the specified manufacturer. Enter a manufacturer string, or use wildcard characters to enter a pattern.

Type:String[]
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Model

Gets the physical disks of the specified model. Enter a model string or use wildcard characters to enter a pattern.

Type:String[]
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-ObjectId

{{Fill ObjectId Description}}

Type:String[]
Aliases:PhysicalDiskObjectId
Position:Named
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False
-SelectedForUse

Indicates whether the cmdlet gets a list of physical disks to host the extents that belong to the virtual disk specified by the VirtualDisk parameter. Specify the physical disks to host the extents of a virtual disk by using the PhysicalDisksToUse parameter of the New-VirtualDisk cmdlet.

Type:Boolean
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-StorageEnclosure
Type:CimInstance
Position:Named
Default value:None
Accept pipeline input:True (ByValue)
Accept wildcard characters:False
-StorageNode

Specifies a storage node as a CimInstance object. The cmdlet gets the physical disk connected to the node that you specify. To obtain a storage node object, use the Get-StorageNode cmdlet.

Type:CimInstance
Position:Named
Default value:None
Accept pipeline input:True (ByValue)
Accept wildcard characters:False
-StoragePool

Accepts a StoragePool object as input and gets the physical disks that belong to the pool. The Storage Pool CIM object is exposed by the Get-StoragePool cmdlet.

Type:CimInstance
Position:Named
Default value:None
Accept pipeline input:True (ByValue)
Accept wildcard characters:False
-StorageSubSystem

Accepts a StorageSubsystem object as input and gets the physical disks attached to the storage subsystem. The Storage Subsystem CIM object is exposed by the Get-StorageSubSystem cmdlet.

Type:CimInstance
Position:Named
Default value:None
Accept pipeline input:True (ByValue)
Accept wildcard characters:False
-ThrottleLimit

Specifies the maximum number of concurrent operations that can be established to run the cmdlet. If this parameter is omitted or a value of 0 is entered, then Windows PowerShell® calculates an optimum throttle limit for the cmdlet based on the number of CIM cmdlets that are running on the computer. The throttle limit applies only to the current cmdlet, not to the session or to the computer.

Type:Int32
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-UniqueId

Gets only the physical disks with the specified IDs. Type one or more IDs (separated by commas), or use wildcard characters to enter a pattern.

Type:String[]
Aliases:Id
Position:Named
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False
-Usage

Gets only the physical disks with the specified allocation method (usage) of the disk. Valid values are AutoSelect, HotSpare, Journal, ManualSelect, Retired, and Unknown.

Type:Usage[]
Accepted values:Unknown, AutoSelect, ManualSelect, HotSpare, Retired, Journal
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-VirtualDisk

Accepts a VirtualDisk object as input and gets the physical disks used by the virtual disk. The VirtualDisk object is exposed by the Get-VirtualDisk cmdlet.

Type:CimInstance
Position:Named
Default value:None
Accept pipeline input:True (ByValue)
Accept wildcard characters:False
-VirtualRangeMax

This parameter is reserved for future use.

Type:UInt64
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-VirtualRangeMin

This parameter is reserved for future use.

Type:UInt64
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False

Inputs

Microsoft.Management.Infrastructure.CimInstance#ROOT/Microsoft/Windows/Storage/MSFT_StoragePool

You can use the pipeline operator to pass an MSFT_StoragePool object to the StoragePool parameter.

Microsoft.Management.Infrastructure.CimInstance#ROOT/Microsoft/Windows/Storage/MSFT_StorageSubsystem

You can use the pipeline operator to pass an MSFT_StorageSubsystem object to the StorageSubsystem parameter.

Microsoft.Management.Infrastructure.CimInstance#ROOT/Microsoft/Windows/Storage/MSFT_VirtualDisk

You can use the pipeline operator to pass an MSFT_VirtualDisk object to the VirtualDisk parameter.

Outputs

Microsoft.Management.Infrastructure.CimInstance#ROOT/Microsoft/Windows/Storage/MSFT_PhysicalDisk

The Get-PhysicalDisk cmdlet returns objects that represent physical disks.