SCSi reservations in clusters based on Windows 2008 (not R2)

SCSi reservations in clusters based on Windows 2008 (not R2)

Hi everyone, welcome again, today I’m writing a quick post on an issue I’ve already seen couple of times. When you remove a disk coming from a SAN from a cluster group in a Windows 2008 (not R2) cluster you are not able to put the resource offline in order to be able to unmap it from the storage array.

Let’s explain briefly what are the SCSI reservations and why a cluster uses it.

Basically, SCSI reservation is a mechanism to lock a device so no other server with access to it can try to use it this way the host that reserved the device is granted with exclusive access to the disk.  Windows clusters use this, and in this great Microsoft’s article you can read how it handles disks resources and reservations over it How the Cluster service reserves a disk and brings a disk online. In fact, if you have a cluster, and you right click on a disk member of a cluster group in the Disk Management MMC snap-in, you will see the ‘Offline’ option is not valid to be selected, this is because the device is reserved. But sometimes even if you removed the disks from the cluster group, they still show as reserved.

How to solve this?

The way I’ve found to solve this, and at this point it is worth to say I’ve only seen this issue in Windows 2008 (not R2), is to reboot both cluster nodes with cluster service down, like the following sequence shows:

  1. Stop cluster service in all the cluster nodes.
  2. One by one reboot the cluster nodes.
  3. Make sure all the disks are offline.
  4. Start cluster service one by one.
  5. Only the disks you intended to remove should be offline at this point.
  6. If you try to remove them from the storage side (I’ve only seen this in HP XP storage frames), the storage might tell you the disk is still in use and you cannot unmap the LUN. This is because even the server has determined it won’t use the disk any more and set it to offline, it hasn’t updated the device, so if you scan for new or updated disks using Disk Management MMC snap-in all the reservations should be gone.

There is another way to clean this much simplex it seems, using SCSIcmd from Symantec, but I haven’t tested it yet, probably when I have a word on that will update this post.

Hope this helps to you!

Hernán J. Larrea

Leave a Reply

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.