Home VCAP-DCA 5 VMFS Storage Maintenance Tasks

VMFS Storage Maintenance Tasks

by admin

Prepare storage for maintenance (mounting/un-mounting VMFS Datastores)

When you un-mount a VMFS datastore, it remains intact but it can no longer be seen from the hosts on which you have unmounted it. The datastore will continue to function as normal on hosts where it hasn’t been unmounted. Operations that cause I/O to the datastore shouldn’t be performed whilst it is in the process of being unmounted from a host.

Important NOTE:  vSphere HA heartbeating doesn’t prevent you from unmounting the datastore. If a datastore is used for datastore heartbeating, unmounting it might cause the host to fail and restart any active virtual machine. If the heartbeating check  fails, the vSphere Client displays a warning.

Before you unmount a VMFS datastore, ensure the following is met:

  • No virtual machines reside on the datastore.
  • The datastore is not part of a datastore cluster.
  • The datastore is not managed by Storage DRS.
  • Storage I/O control is disabled for this datastore.
  • The datastore is not used for vSphere HA heartbeating.

Process to Unmount/Mount a VMFS Datastore using the vSphere Client

  1. In the vSphere client, browse to the datastores view.
  2. Right Click the Datastore and select Unmount
  3. If more than one host has the datastore mounted, choose the host(s) on which you wish to unmount if from
  4. Confirm that you want to unmount the datastore:
vmfs storage maintenance

An unmounted datastore will be shown as greyed out in the Storage view:

To mount a datastore, just right click on it and click Mount:

mount vmfs

Process to Unmount/Mount a VMFS Datastore using the CLI

Using the CLI you can list the mounted datastores on a host by running

# esxcli storage filesystem list

The output will look something like the below screen shot (except with the UUIDs visible!):

unmount vmfs

Looking at the line relating to the datastore I unmounted via the vSphere client earlier we can see the CLI output is also showing it as unmounted:

To mount it we can run:

 # esxcli storage filesystem mount [-u UUID | -l label | -p path ]

If we wanted to unmount the datastore from the command line we could run:

 # esxcli storage filesystem unmount [-u UUID | -l label | -p path ]

References and Useful Links

https://pubs.vmware.com/vsphere-50/topic/com.vmware.ICbase/PDF/vsphere-esxi-vcenter-server-50-storage-guide.pdf

This website uses cookies to improve your experience. We'll assume you're ok with this, but you can opt-out if you wish. Accept Read More