Storage Spaces Direct guidelines

Solution 1:

Speaking shortly, the deployment sequence looks as following:

  1. Deploy necessary WS roles and features
  2. Validate the Failover Cluster
  3. Create the Failover Cluster
  4. Enable Storage Spaces Direct


  1. Create and configure storage pools

Example input:

New-StoragePool -StorageSubSystemName #CLUSTER_NAME# -FriendlyName #POOL_NAME# -WriteCacheSizeDefault 0 -ProvisioningTypeDefault Fixed -ResiliencySettingNameDefault Simple -PhysicalDisk (Get-StorageSubSystem -Name #CLUSTER_NAME# | Get-PhysicalDisk)

  1. Create and configure virtual disks

Example input:

New-Volume -StoragePoolFriendlyName #POOL_NAME# -FriendlyName #VD_NAME# -PhysicalDiskRedundancy 2 -FileSystem CSVFS_REFS –Size 100GB

  1. Deploy SOFS
  2. Create file shares That's it!

Here are two articles that I found helpful:



Solution 2:

My current script for evaluating Storage Spaces Direct

# windows server installation
Install-WindowsFeature Hyper-V, Data-Center-Bridging, Failover-Clustering, RSAT-Clustering-Powershell, Hyper-V-PowerShell -IncludeManagementTools

# before creating cluster set correct MediaType for all disks
#note before setting MediaType disks have to be assigned to a Storage Pool which can be deleted right after setting
Get-Physicaldisk | where size -gt 506870912000 | Set-PhysicalDisk –MediaType HDD

# Create the cluster
New-Cluster -Name w16hyper -Node w16hyper1, w16hyper2, w16hyper3 -NoStorage -StaticAddress

# hack to use RAID cards as JBOD

Enable-ClusterStorageSpacesDirect -CacheState Disabled

Get-StorageSubSystem Cluster*
Get-StorageSubSystem Cluster* | Get-Volume

Get-StorageSubSystem Cluster* | Get-StorageHealthReport

#jobs running on background (eg. rebuild)
Get-StorageJob | ? JobState -Eq Running

Get-StoragePool S2D* | Get-PhysicalDisk | Group OperationalStatus -NoElement
Get-StoragePool S2D* | Get-PhysicalDisk | Sort Model, OperationalStatus

#get log info
Get-StorageSubSystem Cluster* | Debug-StorageSubSystem

Get-PhysicalDisk -Usage Retired

#create new mirrored volume (survive 1 fail for 2node system, 2 simultaneous fails for more nodes)
New-Volume -FriendlyName "Volume A" -FileSystem CSVFS_ReFS -StoragePoolFriendlyName S* -Size 1TB

#create hybrid volume (mirror + parity) with recommended 10% mirror part size
New-Volume -FriendlyName "Volume A" -FileSystem CSVFS_ReFS -StoragePoolFriendlyName S* -StorageTierFriendlyNames Performance, Capacity -StorageTierSizes 100GB, 900GB

#cleanup (pool has to be deleted on each node)
Get-StoragePool S2D* | Set-StoragePool -IsReadOnly $false
Get-StoragePool S2D* | Remove-StoragePool