?
Solved

Over-allocating memory for VM guests

Posted on 2010-09-05
8
Medium Priority
?
945 Views
Last Modified: 2012-08-13
Hi

I had a query on VMWare ESX 3.5 I was hoping someone could help me with. The questions surrounds memory usage.

Let's say the ESX host has 16GB RAM.

I have four guests running on it, each with 4GB RAM assigned. Technically, this should be fine I understand, because the servers won't always be using 4GB RAM, and even if they did, then we are covered.

Now, let's say I added another guest with 4GB RAM. Even if we don't expect the all servers to use their full memory allocation at the same time, can this still cause performance degradation to the host (and therefore other guests)?

In general, what are people's recommendations in terms of allocated RAM v physical RAM?
0
Comment
Question by:kam_uk
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
8 Comments
 
LVL 3

Expert Comment

by:robdcoy
ID: 33607283
Memory management in VMware is much better than other products such as HyperV.  You are correct, you should run into problems.  I have about 20 VM's running on a host with 32GB of RAM.  Each of these machines have more than1.5GB allocated to them.

The only time I run into even a little problem is during backups.  I do host based backup, and depeding on the timing, it does get a little close to the limit of 32GB, BUT that is a night and no one is working anyway.  :o)
0
 
LVL 3

Accepted Solution

by:
robdcoy earned 2000 total points
ID: 33607312
I like to give a quick answer, then follow up with proof:

Attached you will see one of my hosts and the ammount of memory in use vs memory allocated.  This is of course during an off day.

You can reserve memory for the systems you don't want to fall below a certain point such as SQL, Exchange, Domain Controller.  I say this is possible, but I haven't had a problem leaving these at default as unlimited.  I let DRS handle moving servers around on my hosts if things get a little crazy.
2010-09-05-130946.png
0
 
LVL 7

Expert Comment

by:printnix63
ID: 33607375
You might eventually have a look on the discussions at:
http://www.experts-exchange.com/Software/VMWare/Q_26259865.html?sfQueryTermInfo=1+10+30+alloc+esxi+over

Hope it helps.
0
Ransomware-A Revenue Bonanza for Service Providers

Ransomware – malware that gets on your customers’ computers, encrypts their data, and extorts a hefty ransom for the decryption keys – is a surging new threat.  The purpose of this eBook is to educate the reader about ransomware attacks.

 
LVL 3

Assisted Solution

by:robdcoy
robdcoy earned 2000 total points
ID: 33607467
I would also point you to this:

http://www.vmware.com/pdf/Perf_Best_Practices_vSphere4.0.pdf

It goes into great detail.  I would just read a much as you can, then play around with your VM's as I have.  Everyone has a different set of servers thus giving us all different results.  I have had good results with my cluster running it the way I described, and have pretty much fogotten about it.

From time to time, I see another host spining up and taking some VM's, then it shuts down again after the increased load.

Remember, the whole point of VMware was to prevent the use of idle hardware to include CPU, Storage, and Memory so over provisioning Memory is one of the major functions of VMware.  I hear that 4.1 will do an even better job.  I think 150 or so enhancements?  Some of the enhancements are for sure having to do with memory allocation.  I tend to wait for updates until all the bugs are found.  I just downloaded it.

Again, just play around with it (during an off time or scheduled time).  Also, I'm about to go through a server refresh and move up to systems with 64GB of RAM.  I have found that 2008 R2 LOVES memory so I am planning for it.  ;-)
0
 
LVL 28

Expert Comment

by:bgoering
ID: 33607479
VMware has a number of memory management techniques that allow you to overcommit physical RAM while experiencing little or no impact to performance. In ESX(i) 3.5 the two main techniques are Transparent Page Sharing (TPS) and Memory Ballooning.

TPS works well when many of your guests are basically running the same OS, service pack, and patch levels - say Windows Server 2003. The idea is that many of resident memory pages contain identicle code, and VMware only has to maintain a single copy of the page in physical RAM that is shared by all of the similar virtual machines. Same holds true for several Linux, or other OS types.

Memory ballooning requires VMware tools to be installed into your guest virtual machiens. The idea is from within the guest the memory driver in VMware tools understands better the needs of the virtual machine, and is unable to release little used memory pages to ESX to be better utilized elsewhere.

So far a a general rule of thumb that is hard to define. As you can see it depends greatly on how similar your workloads within the VMs are. What you can do is from within the VI Client look at the performance tab, select the memory counters from the dropdown. Whenever you see the "Swap" counter come off of zero that is the point where you may begin to experience some performance impact.

Hope this helps
0
 
LVL 28

Expert Comment

by:bgoering
ID: 33607491
I should proofread - make that "and is ABLE to release little used memory pages..."
0
 
LVL 3

Expert Comment

by:robdcoy
ID: 33607498
All in the PDF link I posted but bgoering said it much better than I did.  I would even say he put it better than VMware!  Hahaha
0
 
LVL 19

Expert Comment

by:vmwarun - Arun
ID: 33608233
Whenever you consider RAM in the virtual world, you also have to take overhead into consideration. The VMKernel needs some memory to manage the VMs which it considers as worlds, each VM runs within its own process and the VMKernel manages the same.
0

Featured Post

Plug and play, no additional software required!

The ATEN UE3310 USB3.1 Gen1 Extender Cable allows users to extend the distance between the computer and USB devices up to 10 m (33 ft). The UE3310 is a high-quality, cost-effective solution for professional environments such as hospitals, factories and business facilities.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

HOW TO: Connect to the VMware vSphere Hypervisor 6.5 (ESXi 6.5) using the vSphere (HTML5 Web) Host Client 6.5, and perform a simple configuration task of adding a new VMFS 6 datastore.
In this step by step tutorial with screenshots, we will show you HOW TO: Enable SSH Remote Access on a VMware vSphere Hypervisor 6.5 (ESXi 6.5). This is important if you need to enable SSH remote access for additional troubleshooting of the ESXi hos…
Teach the user how to rename, unmount, delete and upgrade VMFS datastores. Open vSphere Web Client: Rename VMFS and NFS datastores: Upgrade VMFS-3 volume to VMFS-5: Unmount VMFS datastore: Delete a VMFS datastore:
Advanced tutorial on how to run the esxtop command to capture a batch file in csv format in order to export the file and use it for performance analysis. He demonstrates how to download the file using a vSphere web client (or vSphere client) and exp…
Suggested Courses

765 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question