Check and make sure that the process is actually stuck and not just taking a very long time.
To do this, follow these steps:
1. Make sure SSH service is running on the ESXi host
Once SSH is enabled, connect to the ESXi host using your favorite ssh client.
Find the vmid of the virtual machine, in this case its 20.
4. Find the removeallsnapshots task # then run:
vim-cmd vimsvc/task_info 185720854 <-this # will be different for you
If you see: “The object has already been deleted or has not been completely created” or similar, your snapshot removal is probably frozen, but in order to be sure, let’s look at the file sizes and make sure nothing is changing.
5. cd into the datastore where the vm is located.
6. Now Run ->
watch -d 'ls -lut | grep -E "delta|flat|sesparse"'
Take notice on the file sizes and make sure they stay the same. If they are changing, the snapshot removal process is still working and I would just wait it out. Don’t risk data loss!
7. If the data file sizes doesn’t change for a long time ( 1-2 hours, just to be safe)
Restart the vpxa service on the ESXi host.
Configuration -> security profile -> services -> properties -> vpxa ->options ->restart
Note: You will lose connectivity with the host from vCenter, just reconnect after a minute.
You will eventually see the delta files disappear, and will be able to power on your vm with no snapshots present ! 🙂