VMware Cloud Community
meddle2010
Contributor
Contributor

two hosts in cluster, vms in shared storage, when one host is down, vms show disconnected

I have two hosts in a cluster using shared SAN storage for all VMs and data. Right now I noticed if one host is down, half the VMs show offline/disconnected (they were not running at the time).

Shouldn't the VMs still show online?  their data sits on shared storage that the cluster knows about.

6 Replies
weinstein5
Immortal
Immortal

Do you have VMware HA configured? With out HA configured/implemented  for the cluster the VMs will not fail over in the event of a host failure.

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

No, it was not turned on. This is only in a lab, so it didn't turn it on because I don't have enough RAM in each server to launch all VMs automatically if a host fails.  But I do want to be able to bring up select VMs if a host is unavailable.  And if I take a host out of service, I want VMs to not show "disconnected".  

Will turning on HA prevent this?  Perhaps without it VMs are registered with their last host only, as opposed to the cluster?

Thank you!

0 Kudos
weinstein5
Immortal
Immortal

Do you have vmotion configured? If you do prior to bringing a host down you can vmotion the VM to the host that is going to remain on line - this would be the cleanest and easiest way to keep the VMs up and running and remain connected to vCenter -

HA allows VMs to restart on other host(s) in the cluster in the event of a host failure or a host being shut down -

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

I have DRS on, set to Partial.  The cluster is just a bunch of View desktops, so I didn't need it to vMotion things around automatically.  Being a lab, sometimes they are running, sometimes not.

What I want is to enable the desktops to start on the best host candidate (partial DRS) at the time, then stay there.  If I need to take a host out of service temporarily, I want to be able to shut it down without having all my VMs (currently shut down) showing "disconnected".


I am unclear as to why if they are in a cluster and on shared storage they show "disconnected".   If I manually tell it to start, it will "register" (with the available host(s) I suspect) and successfully start.  But it looks messy and like there is something wrong with half of them showing "disconnected" like that. (not to mention the added time to do this)

Thanks!

0 Kudos
admin
Immortal
Immortal

meddle2010 wrote:

I am unclear as to why if they are in a cluster and on shared storage they show "disconnected".   If I manually tell it to start, it will "register" (with the available host(s) I suspect) and successfully start.  But it looks messy and like there is something wrong with half of them showing "disconnected" like that. (not to mention the added time to do this)

Because they are registered on a specific host, only that host "owns" this VM. This is to prevent any data corrupt that might appear if your second host just thought on a wimp that writing something to the disks of that VM would be a great idea. This host also provides the VM with CPU, memory and networking resources, this will not be combined throughout all hosts in a cluster, that is the reason why you cannot allocate more vCPUs to a VM than the host it is running on does have logical cores.

A cluster is just a logical construct offering some advanced features like HA, vMotion etc. which means in case of failure VMs can be started on a different host or moved to a different host without failure at will. This host will then become the "owner" of the VM.

If you shutdown the host now, these VMs will show as disconnected if you do not move them to the other host prior to shutting it down. This is by design and cannot be changed. Either you move the VMs or you will have them showing as disconnected.

As you seem to have DRS you could set this to Automatic but keep the aggressiveness to the lowest level possible, so it will not move around VMs in your day to day work. But if you put a host into maintenance mode prior to rebooting it or shutting it down automatic DRS will move those VMs to the other host for you with the choice to also register powered off VMs and templates which would avoid the disconnected VMs issue as well.

meddle2010
Contributor
Contributor

Understand the concept of clusters and why ownership is important.   I am used to XenServer where the active database is actually cached on each host (instead of a server off who knows where, that could possibly be updated without the hosts knowing) - so I guess this why this isn't an issue with XS?


Given the different architectures here, and my dev/test environment, sounds like DRS with a low setting and a proactive approach on putting a host into maintenance mode for a evacuation for all VMs before shutting it down is the way to go.

Thanks for clarifying that I wasn't missing anything and for the advice.

0 Kudos