6.7

Table Of Contents
Procedure
1 Browse to the cluster in the vSphere Client.
2 Click the Configure tab.
3 Under Configuration, click VM/Host Rules.
4 Click Add.
5 In the Create VM/Host Rule dialog box, type a name for the rule.
6 From the Type drop down menu, select Virtual Machines to Hosts.
7 Select the virtual machine DRS group and the host DRS group to which the rule applies.
8 Select a specification for the rule.
n
Must run on hosts in group. Virtual machines in VM Group 1 must run on hosts in Host Group
A.
n
Should run on hosts in group. Virtual machines in VM Group 1 should, but are not required, to
run on hosts in Host Group A.
n
Must not run on hosts in group. Virtual machines in VM Group 1 must never run on host in
Host Group A.
n
Should not run on hosts in group. Virtual machines in VM Group 1 should not, but might, run
on hosts in Host Group A.
9 Click OK.
Using VM-Host Anity Rules
You use a VM-Host affinity rule to specify an affinity relationship between a group of virtual machines and
a group of hosts. When using VM-Host affinity rules, you should be aware of when they could be most
useful, how conflicts between rules are resolved, and the importance of caution when setting required
affinity rules.
One use case where VM-Host affinity rules are helpful is when the software you are running in your virtual
machines has licensing restrictions. You can place such virtual machines into a DRS group and then
create a rule that requires them to run on a host DRS group that contains only host machines that have
the required licenses.
Note When you create a VM-Host affinity rule that is based on the licensing or hardware requirements of
the software running in your virtual machines, you are responsible for ensuring that the groups are
properly set up. The rule does not monitor the software running in the virtual machines nor does it know
what non-VMware licenses are in place on which ESXi hosts.
If you create more than one VM-Host affinity rule, the rules are not ranked, but are applied equally. Be
aware that this has implications for how the rules interact. For example, a virtual machine that belongs to
two DRS groups, each of which belongs to a different required rule, can run only on hosts that belong to
both of the host DRS groups represented in the rules.
vSphere Resource Management
VMware, Inc. 100