0

I am trying to set up storage spaces on Windows 10 Pro, but I am confused by the output of Get-Disk and Get-PhysicalDisk:

PS C:\Windows\system32> Get-PhysicalDisk | select DeviceId,friendlyname,serialnumber,canpool

DeviceId friendlyname              serialnumber         canpool
-------- ------------              ------------         -------
2        Samsung SSD 980 PRO 500GB 0025_38BB_0152_4B00.   False
1        Samsung SSD 980 PRO 500GB 0025_38BB_0152_4B51.   False
0        Samsung SSD 870 QVO 2TB   S5SUNF0R209736R        False


PS C:\Windows\system32> Get-Disk | select Number,friendlyname,serialnumber

Number friendlyname              serialnumber
------ ------------              ------------
     1 Samsung SSD 980 PRO 500GB 0025_38BB_0152_4B51.

What I am really trying to achieve is to create a tiered storage pool with disks 0 and 2, using 2 as a cache.

It seems the problem is that these physical disks are not recognized as "logical disks" (if that is a term). I have tried to Initialize-Disk (which is supposed to initialize a partition table) which can't find the disk by number:

PS C:\Windows\system32> Initialize-Disk -Number 0
Initialize-Disk : No MSFT_Disk objects found with property 'Number' equal to '0'.

And I have tried Reset-PhysicalDisk which does nothing to the list returned by Get-Disk.

So, two questions which I think is related:

  • how can I enable a physical disk to be "CanPool"?
  • how can I get disks listed from Get-PhysicalDisk to show up in Get-Disk?
6
  • 1
    Were they converted to dynamic disks?
    – Tom Yan
    Apr 8, 2021 at 9:15
  • I don't know, how do I check? And what does that mean? Do I want them do be dynamic? Apr 8, 2021 at 9:16
  • 1
  • Thank you. This describes using DISKPART and "list disk", but this gives me the same output as Get-Disk, it doesn't show disk 0 or 2, only disk 1 (which is not dynamic, by the way). Apr 8, 2021 at 10:07
  • How do your Device Manager and Disk Managment look?
    – Tom Yan
    Apr 8, 2021 at 10:57

2 Answers 2

1

The answer to your question is simply Get-Disk is logical disks only, and Get-PhysicalDisk returns the attached disk devices, but it looks like you know this.

Get-PhysicalDisk actually has a CannotPoolReason property which may be helpful to you:

Get-PhysicalDisk | Select DeviceID,CanPool,CannotPoolReason

deviceid canpool CannotPoolReason     
-------- ------- ----------------     
0          False Insufficient Capacity
2          False Insufficient Capacity
1          False Insufficient Capacity

Disks to be used in a storage pool must have no partition present (and therefore should not show up in Get-Disk and should not be initialized). Check with:

Get-Partition -DiskNumber 0,2

If you have any partitions listed, or if you have initialized the disks, use Reset-PhysicalDisk to fix. Note that this wipes all data on the disk, so be careful. Sometimes you may have to rescan for disks (or restart the machine) to get them to have CanPool set correctly.

Finally, once your disks can pool, you can create your storage pool. This is just an example, so change the values to suit your needs.

$PhysicalDisks = Get-PhysicalDisk -CanPool $True

# Create the pool
New-StoragePool -FriendlyName "Data" -StorageSubsystemFriendlyName "MyStorage*" -PhysicalDisks $PhysicalDisks | 

    # And, optionally create a partition within your pool to use:
    New-VirtualDisk -FriendlyName "UserData" -Size 100GB -ProvisioningType Thin | 
    Initialize-Disk -PassThru | 
    New-Partition -AssignDriveLetter -UseMaximumSize | 
    Format-Volume

Storage spaces automatically uses your fastest tier of hard drive for caching. Good luck!

[edit] looks like you found an answer seconds before me :^)

2
  • Ok, thank you. My own answer was really unsatisfactory, as it involved booting to linux and removing everything. Anyway, quick follow-up question: do you know if it is possible to boot from a Virtual Disk on a Storage Pool? (I am guessing that the UEFI-BIOS can't handle the storage pool, but what if I put the EFI system partition on a separate disk?) Apr 8, 2021 at 15:31
  • @RolfRander Technically, yes. This is how the new Surface Pro tablets come now, but it may be a surface-bios thing and not necessarily UEFI-compliant. I would not recommend it except for curiosity's sake. Check it out: thomasmaurer.ch/2017/10/…
    – Cpt.Whale
    Apr 8, 2021 at 15:54
0

Ok, I figured this out.

I rebooted from a linux live-USB to take a look at the partition table, and it turned out that the two disks were already partitioned for Storage Spaces. I had opened the GUI for storage spaces and decided that it didn't have the features I want (tiering), but apparently it had already partitioned the drives for storage spaces, and this made them unavailable for all other operations.

I even started reinstalling, but only one disk was available.

It is possible that I could have undone this using storage space management in either the control panel or powershell, but by this time the partitions had already been destroyed in my reinstallation attemt.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .