How to Expand and Resize Storage Spaces Direct CSV Volume? #WS2016 #HyperV #S2D

Introduction

In Windows Server 2016, Microsoft added a new type of storage called Storage Spaces Direct (S2D). S2D enables building highly available storage systems with local attached disks, and without the need to have any external SAS fabric such as shared JBODs or enclosures. This is a significant step forward for Microsoft in Windows Server 2016 software-defined storage (SDS) which reduces the cost even further.

The following diagrams show you an overview of the Storage Spaces Direct stack in Converged (disaggregated) and Hyper-Converged model.

S2D-VolumeExpandResize-00

Storage and compute in separate clusters [Image Source: Microsoft]

s2d-volumeexpandresize-2

Storage and compute in the same cluster [Image Source: Microsoft]

In today’s blog post, I will walk you through how to expand and resize an existing Storage Spaces Direct Clustered Shared Volume(s).

Expand S2D CSV Volume

In this example I am using a Hyper-Converged model with 3 nodes and 3-way mirror disk.
As you can see below, I have four virtual disks in the S2D cluster named “Collect”, “vDisk02”, “vDisk03”, “vDisk04” with capacity of 127 GB and 700 GB.

S2D-VolumeExpandResize-03

And each node has 2 X 960 GB SSDs for caching and 4 X 1 TB HDDs for capacity.

S2D-VolumeExpandResize-07

First things first, we need to check the health, operational status and the foot print on the storage pool of the existing virtual disk before doing any changes.

Let’s open Windows PowerShell and get the existing virtual disk information

S2D-VolumeExpandResize-04

As mentioned earlier, in this example I am using 3-way mirror as resiliency, so for 700 GB virtual disk, it will occupy (700 GB X 3) = 2.1 TB of footprint each.

Here is the Show-PrettyVolume output written by Cosmos Darwin, Program Manager on the storage team at Microsoft.

S2D-VolumeExpandResize-05

Next, let’s check the remaining capacity in the Storage Pool by running the following command:

S2D-VolumeExpandResize-06

The 16.16 TB is the total physical pool capacity, and the 4.56 TB is remaining of the physical storage pool without resiliency.

Let’s see now the maximum resilient capacity that we can add to the virtual disk in order to expand the existing volume(s).

S2D-VolumeExpandResize-08

The remaining mirror capacity is 1.45 TB.

Please note that Microsoft recommends leaving 2 X 1 TB drives’ worth of capacity based on this example, but it’s just that – a recommendation, because if you experience a drive failure, Storage Spaces Direct will not be able to do an immediate and “in-place” repair, meaning it will successfully repair only after you have replaced the physical device. If instead you leave at least 2 TB of free space in the pool, then Spaces would be able to repair immediately, even before the physical disk replacement.

We can confirm this by running the following command:

S2D-VolumeExpandResize-10

Let’s now resize and expand the volume, by running the following command:

Here is another important point to remember: When you are resizing the storage space direct CSV volume, you have to specify the new total size, and not the amount you want to increase, so in this example, the existing virtual disk volume is 700 GB, I need to add 324 GB (new) + 700 GB (existing) = 1,024 GB total. The same concept will apply if you are resizing a Multi-Resilient hybrid volume (Performance / Capacity).

Let’s check now the new size of each virtual disk by running the following command:

S2D-VolumeExpandResize-11

And here is the result shows in Failover Cluster Manager:

s2d-volumeexpandresize-13

We are not done yet, Failover Cluster Manager shows under Disks that the Cluster Virtual Disk(s) are 1 TB in capacity, but the Cluster Shared Volume (CSVFS) is still @ 700 GB as shown in the next screenshot.

S2D-VolumeExpandResize-14

Once the virtual disk(s) is expanded, you will have also to expand the partition size for each one.

Please note that when you want to expand the partition, you need to do to so on the owner node of that volume.

S2D-VolumeExpandResize-15

To automate this process, I created the following script that you can run from your management machine to expand the partition for all volumes.

And here is the final result in Failover Cluster Manager:

S2D-VolumeExpandResize-16

Conclusion

Microsoft has a great Storage Spaces Direct Overview which goes into more detail and is well worth a read.

Hopefully the above notes and screenshots illustrate how you can expand and resize a Storage Spaces Direct CSV volume when you have a need to do so.

Until next time… Enjoy your weekend!

Cheers,
-Ch@rbel

About Charbel Nemnom 306 Articles
Charbel Nemnom is a Microsoft Cloud Consultant and Technical Evangelist, totally fan of the latest's IT platform solutions, accomplished hands-on technical professional with over 15 years of broad IT Infrastructure experience serving on and guiding technical teams to optimize performance of mission-critical enterprise systems. Excellent communicator adept at identifying business needs and bridging the gap between functional groups and technology to foster targeted and innovative IT project development. Well respected by peers through demonstrating passion for technology and performance improvement. Extensive practical knowledge of complex systems builds, network design and virtualization.

4 Comments

  1. HI charbel,

    I’m thinking about replacing how Hyper-v/HP VSA infrastructure with Win2016 Storage spaces direct and VMM 2016. Is Microsoft S2D similar to HP VSA?
    We have two HP DL380 Gen9 /Smart array B140 It is a requirement to be able to present the individual disks directly to the OS as with an HBA/JBOD?

    Thanks

    • Hello Barneaud,

      This is a good move in the right direction.
      S2D is similar and even better than VSA. No VMs are required to create HA storage compare to VSA.
      The overhead is lower, S2D is faster and you can start with 2 Nodes full HA.
      HP DL380 Gen9 with Smart array B140 can do the Job. HBA 240 is also supported.

      Thanks,
      -Charbel

  2. ok thanks,
    Still have problem to get drives to be recognize as SAS in Windows 2016. I changed HP P440ar in HBA Mode.
    Running this powershell command : Get-physicalDisk -Canpool $true | Sort Model show that BusType is still RAID and not SAS, witch if I understood well is not compatible with S2D. Is there any workaround?

    Thanks

    • Prior to configuring Microsoft Storage Spaces using Windows Server 2016, it is mandatory to install the Service Pack for ProLiant (SPP) dated October 2016 or later. This SPP includes the latest firmware and drivers required.

      Those adapters are fully supported by HP with Microsoft Storage Spaces.
      HPE H240 12Gb 2-ports Internal Smart Host Bus Adapter
      HPE H240ar 12Gb 2-ports Internal Smart Host Bus Adapter
      HPE H241 Smart Host Bus Adapter
      HPE Smart Array P741m controller

Leave a Reply