Monday, February 20, 2017

vCenter VM operations error: The operation is not allowed in current state

Today while trying to take snapshot of one the VM, end up with following error,

“The operation is not allowed in current state”

Then I tried to vMotion the VM to any other host but no luck, same was true for any other task however I didn’t see any issue with other VMs on this host.

I also checked for any associated running task but couldn't find any.

I had seen such errors earlier and most of the time such error occur because either the ESXi host or a virtual machine is in an unexpected state and to work around this, we just need to restart the host management agents.

Note: Before restarting the host management agents, make sure no Virtual machine is configured to poweron/off with host otherwise it may reboot.

To restart the VMware host management agent, connect to host over ssh using putty and run following commands,

/etc/init.d/hostd restart

/etc/init.d/vpxa restart

Reference: Related VMware kb# 1003829

That’s it… J