Link to home
Start Free TrialLog in
Avatar of Armitage318
Armitage318

asked on

ESXi 6.7: cannot poweroff VM

Hi, I put one of my ESXi hosts in maintenance mode, but that task is currently in progress because one guest VM seems to have issues.
I am unable to edit anything on that VM, in vSphere console I noticed:
"the operations is not allowed in current state. The operation cannot be performaed because VM migration is in progress"
I tried to shut down affected VM through ESXi hosts (not vCenter).
it seems guest shutdown initiated (it is a very old XP vm!), but if I type:

vim-cmd vmsvc/power.getstate 131
Retrieved runtime info
Powered on

Open in new window


VM still results on.
I also tried with:

esxcli vm process kill -t=hard -w=2236513
esxcli vm process kill -t=force -w=2236513
esxcli vm process kill -t=soft -w=2236513

Open in new window


with no luck.
What else can I try to shutdown this VM?
Thank you!

Avatar of Andrew Hancock (VMware vExpert PRO / EE Fellow/British Beekeeper)
Andrew Hancock (VMware vExpert PRO / EE Fellow/British Beekeeper)
Flag of United Kingdom of Great Britain and Northern Ireland image

Can you find the task and kill the task process ?

Rather than trying to kill the VM ?

It would also be interesting yo find out what Task is running on the VM, e.g. stuck migration, or snapshot in place, or merge.
The shutdown process is in work, but the OS is working oin something. Triggering it again will be denied, as it is already in progress...
..."The operation cannot be performaed because VM migration is in progress "
I'm not sure if it is a good idea to try to kill the VM, as i would expect, that the VM may crash if you just kill it.
So the better idea would be to wait...
May be you are still able to connect via the RDP window (VCenter) if you see any status.

Avatar of Armitage318
Armitage318

ASKER

Unfortunately, I had to forcefully shutdown the entire ESXi host, on which only that VM was "running".
hi Bembi, I waited about 1 hour. Too much time. So in the end I rebootted the host.
Thank you
hi Andrew, did you mean.. finding the task through vSphere web client or through cli?
in vSphere it seems I had no way to end migration process.
How could I narrow the process?
Thank you!

yes troubleshooting is performed at the console or shell too late now a host reboot would do it as a last resort!!!
ASKER CERTIFIED SOLUTION
Avatar of Armitage318
Armitage318

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial