Source: How to unmount a LUN or detach a datastore device from ESXi hosts (2004605) | VMware KB
Umount Datastore LUN
LUN removal checklist
- No virtual machine, template, snapshot or CD/DVD image resides on the datastore
- The datastore is not part of a Datastore Cluster
- Storage I/O Control is disabled for the datastore
- The datastore is not used for vSphere HA heartbeat
- The LUN is not used as a RDM
- The Datastore is not used as a scratch location
- The Datastore is not used as VMkernel Dump file location (/vmkdump/)
- The Datastore is not used as active vsantraced location (/vsantrace/)
- Advanced Settings / Syslog location change to []/tmp
Removal Check list Steps
All items should be self explanatory except the ones below
Scratch Location
Simply change the path to the scratch in advanced settings to []/tmp
Remove Dump File
Check for file, and remove if exists and linked to datastore you are trying to unmount
# esxcli system coredump file list
# esxcli system coredump file remove –force
VSANTraced
To remove the log, simply stop vsantraced, unmount the datastore and start it again:
# lsof |grep vsantraced |grep volumes
# /etc/init.d/vsantraced stop
# /etc/init.d/vsantraced start
Syslog usage
Simple remove the path in advanced settings and click OK