VMware vSphere

 View Only
Expand all | Collapse all

Appropriate HA config so guests restart after power failure??

  • 1.  Appropriate HA config so guests restart after power failure??

    Posted Nov 01, 2010 04:32 PM

    We've had power failures and each time I must manually restart the vCenter Server guest VM, then all the other VMs.

    I know how to do the above from the command line but since our ESX host servers are set to power on when power is restored, I want the guest VMs to do the same.

    What would be the appropriate HA configuration to make this happen??

    This is a 3-host cluster, with 15-20 guest VMs total.

    All hosts are ESX 4.1 with no updates yet.

    Present config is:

    1) both HA and DRS enabled

    2) host monitoring enabled

    3) admission control is 1 host failure -- I know of the 25% recommendation, would it work well for 3 hosts??

    4) das.failuredetectiontime is 60000 (1 minute)

    5) cluster default settings are 'Medium' and 'Power Off' for host isolation response

    6) VM monitoring is presently not enabled -- I have read this can cause unexpected reboots

    What I want is:

    1) Ensure our vCenter Server guest VM stays on its desired host (I have a DRS "should" rule for this, anything else I can do??)

    2) Have our vCenter Server and our domain controller guest VMs with High priority always start when power is restored to the host, plus other guests designated to restart within 'Virtual Machine Options'

    Thank you, Tom



  • 2.  RE: Appropriate HA config so guests restart after power failure??

    Posted Nov 01, 2010 04:37 PM

    sounds to me that since admission control is enabled, you may not have enough resources to failover your guests to the remaining hosts in the cluster. Do you have vCenter4? If so, go to the cluster, and VMware HA, check the Advanced Runtime Info. How many slots are available?

    Also, check

    http://www.vmwarewolf.com/ha-failover-capacity/

    http://www.vmware.com/pdf/vsphere4/r41/vsp_41_availability.pdf



  • 3.  RE: Appropriate HA config so guests restart after power failure??

    Posted Nov 01, 2010 04:42 PM

    After a power failure, all the hosts can successfully restart...

    Two hosts have 24 GB RAM, one has 20 GB RAM.

    Presently 234 total slots, 143 available slots, 13 slots used (13 powered-on VMs presently, some guests are presently powered off).

    Yes, vCenter 4 is the vCenter server.

    All the VMs that we want to restart are set to restart, using either High or Medium priority, but they are not restarting when power is restored.

    Thank you, Tom

    P.S. I think this is the only thing I can do for now?? --> "Set the “Allow Virtual Machines to be powered on even if they violate availability constraints”???

    There's no reservations anywhere for either RAM or CPU.



  • 4.  RE: Appropriate HA config so guests restart after power failure??

    Posted Nov 01, 2010 04:47 PM

    Then you might want to follow s advise. Disable DRS for your vCenter guest and set a restart priority to high. If this doesn't work, then you should look at your HA calculations again, or if all else fails, disable admission control to test.

    for what it's worth, we run vCenter as a VM and don't disable DRS for it, but we do disable admission control. We track our own N+2. VMware's calculations although good, are conservative.



  • 5.  RE: Appropriate HA config so guests restart after power failure??

    Posted Nov 01, 2010 04:40 PM

    1) You can disable DRS for a specific VM

    2) You can set HA restart priority for specific VMs

    Both settings are under Cluster properties.

    Andre



  • 6.  RE: Appropriate HA config so guests restart after power failure??

    Posted Nov 01, 2010 04:50 PM

    Since it sounds like all your hosts are down do to the power failure - what you are describing is not an HA feature but the ability to configure virtual machines running on an ESX/ESXi host to start up and shut down with the host.

    Check out page 141 of http://www.vmware.com/pdf/vsphere4/r41/vsp_41_vm_admin_guide.pdf

    If you find this or any other answer useful please consider awarding points by marking the answer correct or helpful



  • 7.  RE: Appropriate HA config so guests restart after power failure??

    Posted Nov 01, 2010 04:53 PM

    good catch David! If all your hosts fail at the same time, even in an HA environment, HA is smart enough, to just do nothing, which means everything goes down and will have to be powered on manually. However, a double edge sword here. If your Hosts are part of an HA cluster, the startup/shutdown options are disabled, so that would not help in this case either.



  • 8.  RE: Appropriate HA config so guests restart after power failure??

    Posted Nov 01, 2010 05:06 PM

    If your Hosts are part of an HA cluster, the startup/shutdown options are disabled, so that would not help in this case either.

    Hello Troy,

    I was able to enable and set the hosts' startup/shutdown options even though the hosts are in an HA cluster -- does your comment above mean I should disable HA?? Or resign myself to always manually restarting hosts??

    I don't think I lose anything by disabling DRS as you suggest, I don't have enough VMs to approach oversubscribing RAM or CPU.

    Thank you, Tom



  • 9.  RE: Appropriate HA config so guests restart after power failure??

    Posted Nov 01, 2010 05:12 PM

    I was able to enable and set the hosts' startup/shutdown options even though the hosts are in an HA cluster -- does your comment above mean I should disable HA?? Or resign myself to always manually restarting hosts??

    enabling it is not the problem, it can still be enabled, but it won't work in an HA cluster. It's counter productive and could actually have a negative impact on your HA environment, and as you've seen the settings don't stick if you move the VM to another host. In a non HA environment the configured settings follow the VM.

    I think you have a few options. One is to disable HA, then configure your startup/shutdown options. Figure out what's going on in your DC to cause a power outage. Leave HA enabled and know that in the event of a full cluster failure, you'll have to restart everything manually.



  • 10.  RE: Appropriate HA config so guests restart after power failure??

    Posted Nov 01, 2010 05:29 PM

    Hello Troy,

    Thanks for clarifying on the HA and startup/shutdown etc.

    What causes the power outage is weather, the power company not doing enough to prevent power outages, etc.

    We've never had an HA event different than power outages...that is I have not yet seen HA reconfigure anything in our hosts.

    Thank you for explaining that HA as we have it set precludes auto-starting VMs when power is restored...VMware might have a good reason for having it this way but I wish it could do both. :smileyhappy:

    We could be better off not using HA to make it easier on ourselves to have appropriate VMs auto-start. Until/unless VMware does the unexpected and enables auto-start upon power restoration WITH HA. :smileyhappy:

    If I turn off HA in favor of using the startup/shutdown settings, are there any other ways besides DRS affinity rules to ensure that our vCenter server mostly usually stays on the same server as much as possible??

    Are there any alarms for which I should review settings related to power events that HA might normally take care of?? -- if I turn off HA in favor of startup/shutdown settings??

    Thank you, Tom



  • 11.  RE: Appropriate HA config so guests restart after power failure??

    Posted Nov 01, 2010 05:40 PM

    If I turn off HA in favor of using the startup/shutdown settings, are there any other ways besides DRS affinity rules to ensure that our vCenter server mostly usually stays on the same server as much as possible??

    If you disable HA, then I would just use the startup/shutdown options. The VM's will be powered on in the order in which they are added into the automatic startup. However, when that VM migrates, i'm not exactly sure where it goes in the order on the next host. So, to be safe, just disable DRS for your vCenter VM.

    Are there any alarms for which I should review settings related to power events that HA might normally take care of?? -- if I turn off HA in favor of startup/shutdown settings??

    You can look at the Alarm "Host hardware power status" and "Host connection and power state"



  • 12.  RE: Appropriate HA config so guests restart after power failure??

    Posted Nov 01, 2010 05:45 PM

    If you disable HA, then I would just use the startup/shutdown options. The VM's will be powered on in the order in which they are added into the automatic startup. However, when that VM migrates, i'm not exactly sure where it goes in the order on the next host. So, to be safe, just disable DRS for your vCenter VM.

    The migration issue can readily be tested by migrating a less-important VM...I will try this today. The vCenter VM has a DRS affinity rule which says it "should" stay on its particular host but I can turn this off as well.

    Thank you for being so helpful!! Points awarded. :smileyhappy:

    Thank you, Tom



  • 13.  RE: Appropriate HA config so guests restart after power failure??

    Broadcom Employee
    Posted Nov 15, 2010 11:55 AM

    You need to ensure that the primary nodes come back online first. as soon as a primary node is online it should receive the "failover coordinator" role and restart the VMs. (at least to the last known cluster state)

    http://www.yellow-bricks.com/2010/10/22/did-you-know-all-hosts-failed/

    Duncan

    VMware Communities User Moderator | VCDX

    -


    Soon to be release: vSphere 4.1 HA and DRS deepdive (end of November through Amazon.com)

    Blogging: | Twitter:



  • 14.  RE: Appropriate HA config so guests restart after power failure??

    Posted Nov 01, 2010 04:59 PM

    Since it sounds like all your hosts are down do to the power failure - what you are describing is not an HA feature but the ability to configure virtual machines running on an ESX/ESXi host to start up and shut down with the host.

    I checked this out for one host -- it's not enabled, I think this is what I need, since HA will indeed shut them down if power goes away -- more or less.

    On one host, I set our vCenter and one other guest for automatic startup, 2 more for 'any order, the rest for manual.

    I will repeat this for guests on other hosts.

    I recall reading somewhere that vMotioning guests between hosts will reset all these startup settings -- is this true??

    Thank you, Tom