A virtual machine in a vSphere HA cluster is reported as vSphere HA unprotected although it has been powered on for several minutes.

Problem

When a virtual machine is powered on for several minutes, yet its vSphere HA protection state remains as unprotected, if a failure occurs, vSphere HA might not attempt to restart the virtual machine.

Ursache

vCenter Server reports a virtual machine as protected after the vSphere HA primary host that is responsible for the virtual machine has saved to disk the information that the virtual machine must be restarted after a failure. This process can fail for a number of reasons.
  • vSphere HA primary host has not been elected or vCenter Server is unable to communicate with it.

    In this situation, vCenter Server reports the vSphere HA host state for the cluster hosts as Agent Unreachable or Agent Uninitialized and reports a cluster configuration problem that a primary host has not been found.

  • Multiple primary hosts exist and the one with which vCenter Server is communicating is not responsible for the virtual machine.

    Problems occur when vCenter Server is in contact with a primary host, but due to a management network partition, there are multiple primary hosts, and the agent with which vCenter Server is communicating is not responsible for the virtual machine. This situation is likely if vCenter Server is reporting the vSphere HA state of some hosts as network partitioned.

  • Agent is unable to access the datastore on which the configuration file of the virtual machine is stored.

    vCenter Server might be in contact with the vSphere HA primary host that owns the virtual machine, but the agent is unable to access the datastore on which the configuration file of the virtual machine is stored. This situation can occur if an all paths down condition affects all hosts in the cluster.

Lösung

  1. Determine whether vCenter Server is in contact with a vSphere HA primary host, and if not, address this problem.
  2. If vCenter Server is in contact with a primary host, determine whether there is a network partition, and if so, address that problem.
  3. If the problem persists, determine if other virtual machines that use the same datastore for their configuration files are also unprotected.
  4. If these virtual machines are unprotected, verify that the vSphere HA primary host can access the datastore.
  5. If none of the previous steps resolves the problem, restore protection by reconfiguring vSphere HA on the host on which the virtual machine is running.