Can anyone discuss how a host is supposed to behave when it has a bunch of running vms on it and we issue a shutdown or reboot command from the vCenter UI? Sometime it shuts down and the guest vms will boot up elsewhere and other times the host just sort of hangs on shutdown and can take 30-45 minutes to shutdown.
The logs aren't very useful as they basically stop logging and ssh disconnects so my tail log closes as well.
I am just curious as to what the host may be doing\trying to do that causes this delay. Any links or KBs and documentation would be helpful. I have searched but am not finding much. Only a few things that discuss dcui vs vcenter restart that don't apply to my situation.
Thanks for any information or tips you can provide.
Are you asking about ESXi's behavior when it is not in maintenance mode and you perform either of these actions?
Apologies,
I left out some details. Yes I am asking about a reboot or shutdown from vcenter when the host is NOT in maintenance mode. We are testing some applications failover capabilities. I know MM is better and all but we are testing all possible failure scenarios, even a less experienced administrator rebooting a host that is not in MM.
Thank You
In the past (so I'm assuming this is current behavior), if you did a "restart" of an ESXi host via vCenter, this would be basically an ACPI soft-off command and would not trigger an HA response. A "shutdown" would trigger an HA response, however. That said, neither of those are appropriate actions to perform if a host is not in maintenance mode, and should be part of the training and education plan afforded to administrators who have such privileges into vCenter. It's just a right vs wrong way of doing things.
Thank you for the soft shut off information. I completely understand about using Maintenance mode when doing things but we are a software vendor and we design our applications to be resilient enough for a non MM shutdown or reboot. So we test for that during new releases. That is how we discovered it sometimes hangs and other times it is immediate.
Hello hendersp3,
The behaviors are different depending of the configuration of the cluster where the host is located when HA/DRS are enabled/disabled. Also, anytime you try to reboot or shutdown an ESXi that is not in Maintenance Mode you will get this message:
So vCenter is warning you beforehand of what could happen if you click "OK". So the virtual machines will be stopped unsafely and there might be data loss on the vmdks.
However, there are a few things that could assist us: HA and DRS.
When the ESXi is not in Maintenance Mode and you execute a shutdown/reboot on the host:
When the ESXi is entering Maintenance Mode:
Then you can shutdown/reboot the host safely once all the powered on VMs are running in other hosts.
Hope this information helps you out. Let me know if you have any more questions.
Regards.