VMware Cloud Community
Gamleur84
Contributor
Contributor

Start automatically my VMs - in HA cluster

Hello VMworld

I have currently two ESXi in a cluster configured with HA and DRS.

I need to completely shut down my cluster. My question is, I would like to start automatically my VMs when I will power up my hosts.

I know this option is disabled because HA is configured in my cluster... but why ?

1 - I'm trying to find a solution to start my VMs when the cluster  is power up

2 - I'm trying to figure out why this option is disabled when HA is enabled. What kind on problem I can have if this option would be available ? An option like, Start Automaticly VMs when the fist host in the cluster is available... something like that

Thanks !!

0 Kudos
7 Replies
RanjnaAggarwal
VMware Employee
VMware Employee

If you want to start and stop the vm with host for this you have to select the Host ----> configuration tab----->software category ----- > click virtual machine startup and shutdown ----> put a check mark in check box for this option "allow virtual machine to start and stop with the system"

AND THESE OPTIONS ARE ONLY AVAILABLE AT THE HOST LEVEL NOT AT THE CLUSTER LEVEL

Regards, Ranjna Aggarwal
0 Kudos
john23
Commander
Commander

If you are using DRS-HA cluster, Cluster will take care of VM. On cluster level, if you completely down (means all the host in the cluster) , its breaks the cluster rule. If one host of cluster goes down, HA will take care of it and automatically power on the vms. Host level setting will not work since  host is the part of the cluster.

Thanks -A Read my blogs: www.openwriteup.com
0 Kudos
golddiggie
Champion
Champion

You can also put them in the order you want them to startup, with the delays also set. So if you have a domain controller you need to have powered on first, you set that to the top of the list, set the delay to allow it to fully come online before you have the other servers spin up. Or set the delay long enough so that it will be online before any other VM's need to access it's resources.

I use this in my home lab. I have my AD DC spin up first, followed by my SQL server(s) and then my vCenter server. This way everything comes online once it's dependant resources are actually available. Makes for smoother recoveries from power failures and such.

Also not the line right under "Startup Order"... "Power on the specified virtual machines when the system starts. During shutdown, they will be stopped in the opposite order." Something to think about/consider...

0 Kudos
Troy_Clavell
Immortal
Immortal

You may have to script this with something like PowerCLI, because as you noted if your hosts are part of an HA cluster, the startup shutdown options are disabled.  Why that is the case, probably because it would cause confusion for HA plus when the Host comes online, it may still be considered isolated and again cause confusion in the cluster. Also, it could conflict with any HA VM restrart priorities set in place.

0 Kudos
Gamleur84
Contributor
Contributor

Realy not sur what I should do haha

RanjnaAggarwal suggest to configure at the Host Level even if my hosts are in a cluster, but john23 says Host level setting will not work since  host is the part of the cluster.

golddiggie, your lab is configured with vCenter, but are you in a cluster ?

Troy Clavell, if the script is the good option. From where i should launch my script ?

in all cases, thanks for answers ! Smiley Happy

0 Kudos
golddiggie
Champion
Champion

I do have a vCenter server in my test lab. I'm planning on adding anther host to the configuration [soon] so I'll be able to take full advantage of the additional functionality/features that gives me. I just need to hold off until I've moved, where I'll have more space to place another host. I'll also need to recover from the moving expenses, but that shouldn't take too long. Basically, I plan to have this done either by the end of this year, or early next (looking to move in July now).

0 Kudos
john23
Commander
Commander

We only can share what we know... Smiley Happy  (may be we are wrong as well) end result--> you need to decide what really you make out of that....

Hope you get some result.

Thanks -A Read my blogs: www.openwriteup.com
0 Kudos