Prepare storage for maintenance

under_maintenance

Sometimes you will need to perform maintenance on a Datastore which will require placing it in Maintenance Mode and unmounting/remounting it

When you unmount a datastore, it remains intact, but can no longer be seen from the hosts that you specify. The datastore continues to appear on other hosts, where it remains mounted

Instructions

  1. Click Hosts and Clusters View from Home
  2. Select the Host with the attached datastore
  3. Click the Configuration tab
  4. Click on Storage within the Hardware frame
  5. Locate the Datastore to unmount
  6. Right click the datastore and select Properties
  7. Uncheck Enabled under Storage I/O Control and then click Close
  8. Right click the datastore and select Enter SDRS Maintenance Mode
  9. Right Click the Datastore and select Unmount. You should be greeted by this screen warning

unmount

  • Note: The Detach function must be performed on a per-host basis and does not propagate to other hosts in vCenter Server. If a LUN is presented to an initiator group or storage group on the SAN, the Detach function must be performed on every host in that initiator group before unmapping the LUN from the group on the SAN. Failing to follow this step results in an all-paths-down (APD) state for those hosts in the storage group on which Detach was not performed for the LUN being unmapped

Unmounting a LUN from the command line

  • Type esxcli storage filesystem list
  • The output will look like the below

unmount2

  • Unmount the datastore by running the command:
  • esxcli storage filesystem unmount [-u UUID | -l label | -p path ]
  • For example, use one of these commands to unmount the LUN01 datastore:

esxcli storage filesystem unmount -l LUN01

esxcli storage filesystem unmount -u 4e414917-a8d75514-6bae-0019b9f1ecf4

esxcli storage filesystem unmount -p /vmfs/volumes/4e414917-a8d75514-6bae-0019b9f1ecf4

  • To verify that the datastore has been unmounted, run the command:
  • esxcli storage filesystem list
  • The output is similar to:

unmount4

  • Note that the Mounted field is set to false, the Type field is set to VMFS-unknown version, and that no Mount Point exists.
  • Note: The unmounted state of the VMFS datastore persists across reboots. This is the default behavior. However, it can be changed by appending the –no-persist flag.

VMware Link

http://kb.vmware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalId=2004605

 

Leave a Reply

Your email address will not be published. Required fields are marked *

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