Windows10 Pro Storage Spaces, list disks belonging to specific storage pool in PowerShell

The answer to this problem was embarrassingly simple. Coming from an object-oriented background to Powershell seems to have both advantages and disadvantages, as I was searching for the answer from completely the wrong direction. The answer is to use the -StoragePool parameter to the Get-PhysicalDisk cmdlet, as in:

$pool=Get-StoragePool -FriendlyName "MyPool"
$disks=Get-PhysicalDisk -StoragePool $pool

Or in one line

Get-PhysicalDisk -StoragePool (Get-StoragePool -FriendlyName "MyPool")

What have you tried?

What have you searched for?

Are you saying , using the built in cmdlets for storage, you can't get what you are after?

# Verify the existence of storage pools and virtual disks, use
Get-StoragePool 
Get-VirtualDisk

Get-Disk
# Get-Disk cmdlet provides limited insight into physical hardware.

Get-PhysicalDisk –CanPool $True
# Lists the physical disks installed in the server.

Get-StorageSubsystem –FriendlyName *space*
# Determine the storage subsystem's friendly name.

Use the Get-Member cmdlet to see which parameter can be matched up between the to get info for your use case. See the help files / examples for full details

# Get function / cmdlet details
Get-Command -Name Get-StoragePool -Syntax
(Get-Command -Name Get-StoragePool).Parameters.Keys
Get-help -Name Get-StoragePool -Full
Get-help -Name Get-StoragePool -Online
Get-help -Name Get-StoragePool -Examples


Get-Command -Name Get-VirtualDisk -Syntax
(Get-Command -Name Get-VirtualDisk).Parameters.Keys
Get-help -Name Get-VirtualDisk -Full
Get-help -Name Get-VirtualDisk -Online
Get-help -Name Get-VirtualDisk -Examples


Get-Command -Name Get-Disk -Syntax
(Get-Command -Name Get-Disk).Parameters.Keys
Get-help -Name Get-Disk -Full
Get-help -Name Get-Disk -Online
Get-help -Name Get-Disk -Examples


Get-Command -Name Get-PhysicalDisk  -Syntax
(Get-Command -Name Get-PhysicalDisk ).Parameters.Keys
Get-help -Name Get-PhysicalDisk  -Full
Get-help -Name Get-PhysicalDisk  -Online
Get-help -Name Get-PhysicalDisk  -Examples


Get-Command -Name Get-StorageSubsystem  -Syntax
(Get-Command -Name Get-StorageSubsystem ).Parameters.Keys
Get-help -Name Get-StorageSubsystem  -Full
Get-help -Name Get-StorageSubsystem  -Online
Get-help -Name Get-StorageSubsystem  -Examples