• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar

Yellow Bricks

by Duncan Epping

  • Home
  • ESXTOP
  • Stickers/Shirts
  • Privacy Policy
  • About
  • Show Search
Hide Search

Mandatory DRS Rules and HA

Duncan Epping · Aug 24, 2011 ·

On twitter Mike Laverick asked a question around DRS Affinity Rules and if HA would respect these. In this particular instance the question was around VM-Host affinity rules and I noticed multiple tweeps responding and figured it would not hurt to repeat this.

There are two different types of VM-Host affinity rules:

  1. Must aka mandatory
  2. Should aka preferential

The difference between these two with regards to HA is that HA will always respect a must rule. These are mandatory, even if that results in downtime for the VM. The should rule is also known as the preferential rule. In others words it would be nice if this rule can be respected, but if it can’t… no harm.

How does HA know which VM belongs to which host with regards to DRS rules? Well that is fairly straight forward. HA keeps track of which VM is compatible with which hosts. This “VM to Host compatibility list” is used for portgroups and datastores but also for DRS rules. Check the screenshot below for a hint…

Mandatory DRS Rules and HA

Please note, this is a very old article about HA, there are tons of new articles on this topic. Just do a search on my blog, or download my ebook freely available via Rubrik.

Share it:

  • Tweet

Related

BC-DR, Server 4.1, 5, drs, ha, vSphere

Reader Interactions

Comments

  1. Mike Laverick says

    24 August, 2011 at 16:08

    Cool. Just to contextualize this a little more. The question came up in the context a virtualized vCenter, running on top of a cluster that its managing.

    A popular complaint is if the ESX host dies on top of which was a virtualized vCenter – “I can’t find my VC” (Erm, powerCLI?) but if we can limit the VC to failing over smaller number of hosts (not the entire cluster) folks will play less “hunt” the vCenter…

    Regard
    Mike

    • Mike says

      24 August, 2011 at 16:16

      True true … Or just store the VM on local storage and disable DRS for it :p

      Man I hope we can download vSphere 5 soon – I keep reading all the nice nuggets here on YB not being able to actually implement any of it .. Wished vmware would stop paper relases 🙁

  2. Victor Forde says

    24 August, 2011 at 16:29

    Found your note useful and as a newbie to VMware I wanted to go one step back and find out what it is and where to use it. This helped http://www.petri.co.il/host-drs-affinity-rules-vsphere-4-1.htm

  3. tom miller says

    24 August, 2011 at 17:33

    Mike – check this thread – it deals with your question

    http://communities.vmware.com/message/1793895#1793895

    • Mike says

      24 August, 2011 at 18:37

      Getting “Unauthorized” error when trying to view the link

      • tom miller says

        24 August, 2011 at 19:58

        Sorry Mike – I thought you had access to the RCbeta. Here is a snippit: Thanks Craig. My thought process was I always want to know where vCenter and or AD is running. I setup DRS Host groups to accomplish this. I actually never noticed the option of “should” verses “must”. Switching to “should” accomplished my goal. Now when a HA event occurs the AD server restarts on the other host and when the affected host recovers AD gets automatically moved back. This also helps with patching a host as well. Before with “must” I could not vMotion the VM to the other box. With “should” it works as I originally intended.

        Thanks for pointing out the “should” option!

        Tom Miller

        • Mike says

          24 August, 2011 at 20:07

          I wish …being solution partner doesn’t seem be enough to be ‘allowed’ into the beta 🙂 Thanks Tom, much appreciated.

          • tom miller says

            24 August, 2011 at 20:25

            No Thanks needed. Your website is at the top of my RSS feeds. Your work on SRM is out of this world. When can we expect SRM5? I see the roughcut.

        • Mike says

          24 August, 2011 at 21:54

          I think you think about the wrong Mike here – I have nothing to do
          with SRM 🙂

  4. Dharshan says

    27 February, 2012 at 21:53

    Host Affinity rule has got a bug.

    Under new rule of DRS comes with vsphere 4.1

    VM to host.

    I can create rule with same Cluster VM group and Cluster host group, with different affinity rule like but no conflict occurs, So which rule will get effective.

    Must Run -Required.
    should RUN -preferential.
    must not run -Required.
    should run Preferential.

    This seems not trust wroth..

    But with case of DRS rules like

    Keep virtual machine together
    seperate virtual machine together

    DRS automatically disables the second rule.

    Thanks in Advance for your answers..

Primary Sidebar

About the author

Duncan Epping is a Chief Technologist in the Office of CTO of the Cloud Platform BU at VMware. He is a VCDX (# 007), the author of the "vSAN Deep Dive", the “vSphere Clustering Technical Deep Dive” series, and the host of the "Unexplored Territory" podcast.

Upcoming Events

29-08-2022 – VMware Explore US
07-11-2022 – VMware Explore EMEA
….

Recommended Reads

Sponsors

Want to support Yellow-Bricks? Buy an advert!

Advertisements

Copyright Yellow-Bricks.com © 2022 · Log in