DRS Host Affinity rules

One of the new features in vSphere 4.1 is the ability to configure Host affinity rules for DRS. These enable you to split your vSphere cluster in several groups of hosts and assign assign a subset of your VMs to one of these groups.

There are plenty of use cases for this:

– Netapp Metrocluster

– Applications licensed based on CPUs

– performance sensitive applications

– …

In my case the cluster is spread over 2 sites, one production site and a failover site. The failover site is used to run test & dev servers. Only in case of serious problems on the production site the VMs should be moved to the failover site.

Open the cluster settings and create a “Virtual Machines DRS Group”

100818 - Screenshot- EVC-Cluster Settings - 001_ver001

I create a group called FailoverSiteVMs which contains the test & dev servers.

100818 - Screenshot- Edit DRS Group - 001

A second group is called ProductionSiteVMs which contains the production virtual machines.

image

Now we need to create 2 “Hosts DRS Groups. One for the FailoverSite.

image

And another one for the Production site.

100818 - Screenshot- Edit DRS Group - 004

An overview of the configured groups

image

Once all the groups are created you can start creating DRS rules. Select the “Virtual Machines to Hosts” as type, the Cluster Vms Group and the Cluster Hosts Groups.

There are 2 main types of DRS rules:

  • Should run on hosts in group
  • Must run on hosts in group
    The “Should run on hosts in group” rule keeps the VMs on the configured hosts but HA can violate the DRS rules and start the VMs on the failover hosts.

When the “Must run on hosts in group” type is used HA won’t violate the DRS rules and the VMs won’t be restarted on the failover hosts.

100818 - Screenshot- Rule - 001

Once the rules are configured the rules dialog looks like this.

image

Tagged with: , , ,
Posted in Virtualization
IT Pro Summer GP
IT Pro Summer Grand Prix
MVA
Microsoft Virtual Academy
Pro-Exchange
Pro-Exchange / Pro-Lync / Pro-Office365
MEET

Enter your email address to subscribe to this blog and receive notifications of new posts by email.

Join 158 other followers

%d bloggers like this: