Saturday, January 16, 2016

ESXi host stuck "in progress" when exiting maintenance mode

This was the first time when I came across such an issue where exit from maintenance mode was taking a long time and appearing like stuck on 15% (waited for at least 20 minutes). To see what's going on the host, connected to the host using Putty and checked the maintenance status of host using the vim-cmd command,
#vim-cmd hostsvc/hostsummary |grep inMaintenceMode  
And I was amazed to see the output, it was clearly showing the host has exited from maintenance mode while from GUI it was still showing in progress.
Then I thought vSphere client might not refreshed the task status so closed the connection and then reconnected to vC again. This time there was some progress, but still, it was taking too long to Exit from maintenance mode.

Whenever we see this kind of unusual issue, we look at the restart of host management agents. 
I have a bad experience in the past with restarting all the agents at once using #services.sh restart (it takes a long time to complete), so prefer to restart host and vCenter agents individually using below commands,

#/etc/init.d/hostd restart
#/etc/init.d/vpxa restart

Now coming back to the point, this fixed the issue however the host was showing like the HA agent didn’t installed correctly so again I put the host back into the maintenance mode and once the task completed, exited from maintenance and this time there was no issue.

That’s it… :)


4 comments:

  1. We have experienced the same issues, and the same fix (most of the time). Any ideas or updates on how to prevent this from happening (we have over 100 hosts to manage)?

    Jim

    ReplyDelete
    Replies
    1. This issue itself is a rare occurrence and this is the only fix i am aware of.

      Delete
  2. thanks, your solution works like a charm.

    ReplyDelete
  3. Good to know that it helped 😊

    ReplyDelete