Partager via


Cluster Shared Volumes (CSV) – Extending a Volume

There are often times where you have a need to expand a LUN when running enterprise systems.  This is a trivial action in most cases because you simply add physical drives to the array and then use Disk Management to extend the drive to encompass the newly expanded volume.  Unfortunately, on highly-available systems such as those running Failover Clustering with Cluster Shared Volumes (CSV)-enabled features the drive is reserved and un-manageable by Disk Management.  However, this procedure is possible and capable of being done without any loss of service to client services such as virtual machines.

First:  Extend LUN using OEM-specific tools

The first step isn’t one that I can document specifically because it is OEM-specific for the toolset.  As you know, SAN’s are a form of Shared I/O and due to this they are managed using a set of proprietary tools (usually) and as such I can’t really provide guidance because of this.

However, to summarize a bit what you should do is similar to the following steps as I performed on our EMC Clarion AX4-5 using Navisphere Express -

  1. Connect to Navisphere via browser
  2. Click Disk Pools
  3. Click Extend
  4. Provided percentage or size

After extending the LUN, I verified that the LUN was fully extended through the Navisphere client and when completed, I moved to the next step.

Second:  Find the CSV Owner

To find the owner of the CSV, the easiest method is to use the Failover Clustering administration tool.  This can be found on any of the cluster hosts or you can install on your workstation as part of the Remote Administration Tools for Windows 2008 R2.

To determine the CSV owner, do the following:

  1. Click Start, Administrative Tools, Failover Cluster Manager
  2. Connect to the Cluster by clicking Manage Cluster from the MMC action pane
  3. Highlight the Cluster Shared Volumes node, and locate the server name under Current Owner

image

This server name will be used in Step 3.

Third:  Remote Desktop (RDP) to CSV Owner Server

CSV’s are a tricky “volume” unlike many seen in the past.  The entire LUN is presented to all hosts in the cluster; however, the lock for each server is done at the folder level rather than the traditional LUN level.  This allows n number of hosts to all connect to a LUN but only own the applications contained in the folders they utilize.  Beyond that, the drives that are managed in Disk Management are set as reserved and un-manageable using the UI hence causing trickiness.  Using the information determined in Step 2, let’s RDP to the server.

To RDP to the server, just use mstsc /v:{server FQDN}

Fourth:  Use DiskPart to Extend Volume

The last step, now that you are at the server who owns the CSV, is to execute DiskPart and issue the command to start the extend process.  To do this, you do the following -

  1. Run DiskPart from an elevated command prompt
  2. Type rescan
  3. Type list volume
  4. Type select volume {enter volume number from output from #3 step}
  5. Type extend

To confirm that all changes were taken and that the volume is the correct size, you can do the the list volume command again and verify the size change from step 3 above.

Summary

In this post, we focused on a scenario where you’ve “outgrown” your planned capacity and you now need to extend your CSV-based volume.  Unfortunately, the traditional methods of extending the size of a drive isn’t capable of being used due to the tools (Disk Management) disabling the functionality.  The next challenge, though, is finding the volume with DiskPart and the trick here is to find the CSV owner and execute the toolset from this server.  After doing this, your LUN should extend to the size you provisioned in your OEM-specific tool.

Thanks,

-Chris

Comments

  • Anonymous
    January 01, 2003
    And how about Shrinking a Volume? Can it be done as easily? or some special considerations are needed?

  • Anonymous
    January 01, 2003
    Hi- The reason you have to do this is based on how Clustered Shared Volumes (CSV) works.  Even though the LUN is shared among multiple hosts, their is still an actual owner of the disk.  There is a great read here blogs.msdn.com/.../9453288.aspx that explains in more detail.   However, as you point out, you don't have to RDP if you don't like as you could remotely connect using any other server management technique.  I'm unsure (or unaware) if diskpart is "remoteable" and if it is then you don't have too.  If you have another method, I would love to here from you... Nonetheless, I wrote this post for simplicity and the simplest way I found was to RDP to the owner and extend. Thanks for your comment! -Chris

  • Anonymous
    January 01, 2003
    Hello Chris Adams I just want to know why we should use RDP to connect to CSV owner server to run diskpart utility? thanks

  • Anonymous
    January 01, 2003
    Hey Luxspes- That is a great question.  I don't honestly know if that can be done easily.  I'm currently on holiday but what I will do for you is carve a small piece of my SAN off and try and see if I can do such a thing.   I'm hesitant to say it is supported or recommended due to the fact that once you've allocated the storage at the hardware level I'm not sure if you can shrink.  However, it is certainly worth a try.   Check back with me the week of Jan 3rd and I will post a quick update or maybe even a whole new blog depending on the outcome. Thanks, -Chris

  • Anonymous
    January 01, 2003
    So... did you make the experiment?

  • Anonymous
    January 01, 2003
    Just to leave a note, some SAN vendors have storage management tools that coordinate between the SAN and disk management to automate the process of expanding and shrinking LUNs, including CSVs. NetApp's SnapDrive is one example.

  • Anonymous
    January 01, 2003
    Basically what I would like to know is if I can shrink the partition (I do not think I need to shrink the LUN) basically my problem is that I configured my cluster for an odd number of nodes, and now I need to configure it for an even number, but for that I need to have a witness disk, and I configured my SAN with a single 4TB Lun (and a single 4TB partition!) so now I need to shrink my partition to create space for a partition that will act as witness disk (AFAIK all I need to do is to shrink the partition (using Diskpart or even the GUI Disk management tools), not the LUN, am I correct?)

  • Anonymous
    January 01, 2003
    I followed the exact process to extend disk space. it shows the disk space on onwer server but does not show in cluster storage.
    Please have look at following link for more details:
    https://social.technet.microsoft.com/Forums/windowsserver/en-US/abd6c1d5-1365-433b-89ad-131c3246bb3f/cluster-storage?forum=winserverfiles

    Thanks

  • Anonymous
    December 23, 2013
    Pingback from My Frustration with HyperV, do you really save anything? | Justin's IT Blog

  • Anonymous
    April 07, 2014
    Thank you so much! This worked like a charm.

  • Anonymous
    January 30, 2015
    We've also found that if you extend the volume on the host that is not the owner, you run into an issue where the extended space is not shown in Failover Cluster Manager. The way we solved the issue is that we extended the LUN by any amount (1 GB or more) and than extended the volume with diskpart on the owner. This solved our issue.

  • Anonymous
    August 10, 2015
    Very useful information. Thank you for your post.