vsphere_static_160x300
Badges

vexpert_logo_100x57

gestaltitbadge

follow-me-twitter

Subscribe to me on FriendFeed

Comments / DISQUS
Feedjit.com

Designing ESX Resource Pools

How do you design resource pools in an ESX Cluster? There are two strategies that are the most popular in my experience. The first strategy creates resource pools based on CPU and Memory shares for host resource conflict management, and the second strategy uses reservations and limits to guarantee physical resources and ensure VM containment. This post will use a 3 ESX host example to explain both strategies. Please feel free to comment on the pros and cons of each or why you think one is better than the other.

In the example scenario three ESX hosts each have 16 GB RAM and 2 dual core 3.0 Ghz CPUs. The three hosts will all be members of the same ESX cluster.

I tried to create design names that illustrate the strategy. I am not aware of any specific resource pool design naming from VMware.

The Tug of War design

This design is simple and does not limit any VMs from any physical resources. Using the ESX shares mechanism, if two or more VMs are competing for the same physical resources the tug of war that results will be decided by the resource pool memberships of the VMs.

The ESX cluster will have three resource pools defined.

  • A “High” resource pool will have no initial reservation and unlimited/expandable RAM and CPU settings. CPU and Memory shares will be set to high. This resource pool will be devoted for mission-critical VMs.
  • A second “Normal” resource pool will have no initial reservation and unlimited/expandable RAM and CPU settings. CPU and Memory shares will be set to normal. Normal priority service VMs will be placed into that resource pool and the shares guarantee that VMs in this resource pool do not have priority over mission critical VMs.
  • A third “Low” resource pool will have no initial reservation and unlimited/expandable RAM and CPU settings. CPU and Memory shares will be set to low. Low priority service VMs, development, and non critical VMs will be placed into this resource pool and the shares guarantee that VMs in this resource pool do not have priority over normal or high VMs.

The three resource pools configured by shares will ensure that the proper VM has priority to physical resources when a conflict occurs. Resource conflict management can take place with the full capacity of the ESX cluster’s physical resources.

The Pizza Design

updated 03.09.08

This design takes the sum total of all physical resources and slices it up across the resource pools. Although the following design only uses two resource pools, many more “slices” could be created. The most basic Pizza Design would be to reserve all memory and cpu, but the following example helps also illustrate reservations and limits.

The ESX cluster will have two resource pools defined.

  • A “Critical Services” resource pool will have an initial reservation of 32GB RAM and 8GHz CPU, and unlimited/expandable RAM and CPU settings. This resource pool will be devoted for mission-critical VMs. Shares for RAM will be set to high, but shares for CPU will be set to normal.
  • A second “Non Critical Services” resource pool will have no reservation and a limit of 16GB RAM and 4GHz CPU. Shares for Memory and CPU will be set to normal. Low priority service VMs will be placed into this resource pool and the limits guarantee that VMs in this resource pool do not over consume resources.
  • The remaining balance of CPU is fully available to the Critical Services pool because of the expandable reservation.

This specific design example was based on a mix of VMs that were expected to contend for memory more often then cpu.

Final Thoughts

I usually start a design with the tug of war strategy. Resource Pools can be confusing, complicated, and difficult to troubleshoot if the design gets complex. Starting out simple makes sense until a specific VM performance issue is determined. On the other hand, the pizza design is a better starting point if you know you will have heavily used development VMs mixed in with your production VMs. The pizza design ensures that if a developer launches a rogue script on one of the VMs then the production system will not be impacted.

LOL! After writing this I am hungry for some pizza ….

Related Posts

  • andrew000
    Does anyone have any thoughts on the best way to deliver web applications? I currently have 50+ web sites running on 10 odd servers and a clustered NLB web service for high demand/high availability sites. I need to implement a virtual environment, where sites that receive short burst of high activity can be handled along side sites with a trickly of visitors. Any recommendation of how I should configure a resource pool, VMotion, DRS, and HA.
  • Clive,

    Thanks for asking this. It made me realize I should be a little more clear about the pizza design. I will update the Pizza Design section to point out the use of the remaining CPU.
  • Clive
    Hi Rich,

    Interesting article, thanks!
    My question is on how the CPU resources are calculated and then split up for the pizza box example.

    Ignoring service console overhead etc, the total CPU in your example (3 servers each with 2, dual core 3.0GHz CPU)
    i.e
    3*(2*(2*3)))
    = 36GHz
    = 36000MHz

    So why do the resource pools in the pizza box example use all the available RAM but not all the CPU?
  • Terry,

    All of your comments / questions are correct.

    Yes, use 0 reservations and make sure the unlimited box is checked for all resource pools in the tug of war design.

    Yes, when you add VMs to any pool they inherit the settings. If 2 guests battle over the same resource, say one is in the HIGH pool and the other is in the NORMAL pool, then the VM in the HIGH pool gets priority to the resource.
  • Hi Rich,

    I read your article with great interest as I'm looking for a simple implementation of resource pools. I am paticularly interested in the Tug of War model.

    One thing I can't wrap my head around. When placing a vm into one of the resource pools does the vm take on the characteristics of the pool? And, how should the resource allocations be set within each vm? Normal shares, 0 reservations, Unlimited?

    Is my understanding right that if I drop a vm in the "High" resouce pool it will behave within the cluser as if it has High Cpu and memory shares? Then if I take that same vm without modification and drop it into a normal or low pool it would behave accordingly. If so than that is the model for me. I believe in using all the resource available and adjusting priorites via shares.

    Thanks for the article and your time.

    Cheers

    Terry
blog comments powered by Disqus
Hyper9 Cowabunga
Support VM /ETC
Support VMETC.com

Support VMETC.com

Free Business and Tech Magazines and eBooks
@rbrambley tweets
Advertisements
VMTN Roundtable Podcasts
Subscribe



Add to Google Reader or Homepage
Subscribe in NewsGator Online
Add to netvibes
Add to Plusmo