I have a VM that is reporting a connection to the local datastore on its host, and as a result I cannot vMotion it elsewhere. The VM has two virtual disks, both of which are on SAN storage. The VM previously was connected to an ISO on the local datastore, but it has since been changed to client device. It still insists that it is using something on that datastore, however. I've looked through the vmx file and don't see any reference to it. I also tried unmounting the datastore, but it claims the file system is in use. The hosts were recently updated to esxi 6.0 U2, and this is the only VM that seems to be exhibiting this behavior. Any suggestions on what might be causing this? This is a fairly important server in this environment, and being locked into a single host is making me a little anxious.
Turns out it was due to an old snapshot. If you mount an ISO from a datastore and take a snapshot, the VM will keep a link to that datastore even after changing it to client device. As soon as you delete the snapshot, that relationship goes away, and access to that datastore is no longer a consideration when finding valid hosts.
Hi there,
On the host can you run the following which will return the list of all open files <YOUR_VM_NAME> currently has, to see if it shows any connections to local datastore:
lsof | grep <YOUR_VM_NAME>
Also are you able to storage vMotion the VM? This should shift all files onto different storage and may clear the error.
vM
-----------------------
VCAP-DCD / VCAP-DCA / VCP-CLOUD / VCP-DT / VCP5 / VCP4
-----------------------
vMustard.com
Turns out it was due to an old snapshot. If you mount an ISO from a datastore and take a snapshot, the VM will keep a link to that datastore even after changing it to client device. As soon as you delete the snapshot, that relationship goes away, and access to that datastore is no longer a consideration when finding valid hosts.