Unfortunately from time to time you can end up in a situation where your virtual machine is not reacting anymore on operations like vMotion, power-on or releasing a snapshot.
The cause is very often a locked VMDK file or CBT file (changed block tracking used by backup software) by a different ESXi than the one running your virtual machine and the corresponding process. That can be a leftover from purple screens, SAN connection failures or complete power outage.
Taking the example of powering on the virtual machine, the host the virtual machine is registered on tries to lock the VM files and start the VM runtime. As the locking doesn’t work because the file/s are already locked by a ESXi Host (typically the ESXi host the VM used to run before) the operation throws an error.
If you don’t use any tools, you need to work your way through the log files and some CLI commands.
Manual steps to release the VMDK lock
- find the IP address of the locking host – lock owner
- find the host locking the file (by IP address)
- find the locking process and release the file lock
Further information to detect lock owners and release the VM file lock
There are two great VMware Knowledge Base articles that describe the step by step process, if you want to go the manual way: