This article provides the required steps to successfully complete the datastore detach or unmount workflow, which might be impacted due to the placement of vSphere Cluster Services (vCLS) VMs.
When attempting to unmount or detach a VMFS, NFS, or vVols datastore, the operation fails with one or more of the following:
The resource 'Datastorename' is in use. Cannot unmount volume 'Datastorename' because "One or more virtual machines are still registered on it". Correct the problem and retry the operation.Error unmounting /vmfs/volumes/####: Filesystem is busy (ref 11).vmkernel.log contains warnings regarding active virtual machine locks or outstanding worlds against the device backing the datastore.vCLS-####) are visible in the file browser.This issue occurs due to the presence of running vCLS Agent VMs on the datastore. Because these VMs maintain open file locks to ensure cluster services (DRS/HA), the host is prevented from unmounting the volume. These VMs are often hidden from the standard vCenter inventory.
Prior to unmounting or detaching a datastore, you must ensure that vCLS VMs are moved or removed to release active file locks.
Option A: Migrate vCLS VMs (Preferred) If there is another datastore attached to the hosts within the cluster, migrate the vCLS VMs:
Option B: Enable Retreat Mode If the target datastore is the only storage or if migration is not possible, use Retreat Mode to temporarily delete the VMs.
For vCenter 7.0 U3o / 8.0 U2 and Later:
For Versions Prior to 7.0 U3o / 8.0 U2:
config.vcls.clusters.domain-c####.enabled to False (Replace #### with the cluster's domain ID from the URL).Note: If the datastore is shared between multiple clusters, Retreat Mode must be enabled on all clusters connected to that datastore. DRS will be non-functional while Retreat Mode is active.
True) to redeploy the vCLS VMs to available datastores and restore DRS functionality.