I have a new system running under VMware, and I'm just trying to make sense of the memory use.

In vSphere client, it shows me active using 335,544 KB:

enter image description here

However, linux shows me using 3,146,148 KB:

root@PFDEV-SVN:~# free -k
             total       used       free     shared    buffers     cached
Mem:       4118636    3146148     972488          0     477216    1268364
-/+ buffers/cache:    1400568    2718068
Swap:      6040400          0    6040400

Why is this so different? Am I just reading this incorrectly?

This is Ubuntu 9.10, without vmware tools installed, running on an ESXi server.


There is a detailed white paper on the topic of memory management and calculations of the active memory working set size.

It basically all boils down to the fact that a guest is not using all the memory that has been assigned to it all the time. Instead, only certain ranges of memory are considered "active" at a particular time period, making the "inactive" memory a candidate for swapping, if you happen to overcommit your physical memory. You should look at the "consumed" memory if you want to roughly match it up with the memory usage within your host (deviations due to memory pages shared across several VMs may occur).


One would hope that they do not match. One of the purposes of virtualization is to allow many OSes to reside on 1 physical system. One of the things noted when building a hypervisor (like ESX or hyper-v) is tha toperating systems often do not actually use all of the ram allocated to them. hypervisors will accordingly make thta physicla ram available to other OSes allowing you to "overcommit" on the amount of ram available. the downside to overcommiting is that should you run into a situation where each OS actually uses the amout of ram allocated, performance will degrade.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.