Force VM to be on different nodes

Hi to all
is possible, with One, to force some VM to be placed always on different hosts?
In example, VM1 and VM2 must be always on different hosts and never on the same, except only one host is available.

Let me try to explain better. Let’s assume a 3 nodes environment.
We have two DNS servers (dns1, dns2) running on this environment.
We would like to force One to always run dns1 on a different node than dns2, for redundancy reasons. If both are running on the same node, a node failure will bring down both machines.

If two nodes are down, then and only then, One should restart both dns1 and dns2 to run on the only survived host.


Please take a look at the scheduler documentation.

Kind Regards,
Anton Todorov

Deploy only in the Host where VM <ID> is not running

Thank you for the response
So i have to match the vm-id? Isn’t possivike to use a different string like the vm name or anything else easier to remember?

What if there isn’t any host available? Vm will stay in pending or executed on the host regardless the requirements?

@gandalf, from the documentation it seems it support VM ID only. Let the Developer to confirm on this.

If no host available, it will be in pending state. You have to manually deploy in any host.


CURRENT_VMS only supports the numeric vm id.

In that case the vms stay in pending until a suitable host in found.