VMware Cloud Community
mahmn
Enthusiast
Enthusiast

Memory usage of VMs and node information

The following 4  figures show the memory consumption of 4 VMs on a node. Other nodes are powered off.

1.png

2.png

3.png

4.png

As you can see, from 6 AM, the total memory usage is about 12G+7.5G+2G+15G which is 36.5GB.

Below, you can see the memory usage of that node.

5.png

As you can see the black line is much greater than 36.5GB (since 6 AM).

What that can be explained?

7 Replies
scott28tt
VMware Employee
VMware Employee

By “node” do you mean “ESXi host”?

Why would other “nodes” being powered off be relevant? Is the host part of a cluster?

And the 5 charts, the first 4 are the only VMs running on that ESXi host, with the last chart being a view of that ESXi host?


-------------------------------------------------------------------------------------------------------------------------------------------------------------

Although I am a VMware employee I contribute to VMware Communities voluntarily (ie. not in any official capacity)
VMware Training & Certification blog
Reply
0 Kudos
mahmn
Enthusiast
Enthusiast

Yes. Node 10.1.1.101 is ESXi host.

I forget to add the vcenter and a file server information since in addition to those VMs, vcenter is also on that node.

Here is the vcenter chart.

Fig 6

6.png

Here is the file server

Fig 7

6.png

As you can see, the summation of memory usage of figures 1~4 plus 6~7 is less than what we see for the node in figure 5.

Also the ESXi information is shown below. However, I only see last hour and not last day.

Fig 8

6.png

Reply
0 Kudos
mahmn
Enthusiast
Enthusiast

The VMs memory according to the figures are

Fig 1 => 12 GB

Fig 2 => 7.5 GB

Fig 3 => 2 GB

Fig 4 => 15 GB

Fig 6 => 10 GB

Fig 7 => 2 GB

Total is 48.5GB

According to ESXi information (Fig 8), it is about 52 GB

and according to the vsphere chart (Fig 5) it is less than 54 GB.

I think the information is correct.

Sorry for taking up your time.

You can close this thread...

Reply
0 Kudos
Ardaneh
Enthusiast
Enthusiast

I couldn't realize what is the VM memory metric that you chose from the pictures, but there are different memory metrics that can be used to monitor memory usage in ESXi:

- VM Active Memory: defined as the amount of guest memory that is currently being used by the guest operating system and its applications.

- Host Consumed Memory: defined as the amount of host memory that is allocated to the virtual machine.

So ESXi consumed memory is always higher than VM active memory.

"The hypervisor knows when to allocate host physical memory for a virtual machine because the first memory access from the virtual machine to a host physical memory will cause a page fault that can be easily captured by the hypervisor. However, it is difficult for the hypervisor to know when to free host physical memory upon virtual machine memory deallocation because the guest operating system free list is generally not publicly accessible. Hence, the hypervisor cannot easily find out the location of the free list and monitor its changes."

Please share full screenshots of your chosen memory metrics

I hope it could be helpful

mahmn
Enthusiast
Enthusiast

Thanks for the explanation. I have to say that previous question has been solved.

So, I would like to ask a new one.

As you can see in the figure below, windows task manager shows that about 7 GB of memory is active (from total 24 GB memory).

Also, the real time chart from vspehre for that VM also shows active (blue) and consumed (green) as 7GB and 24 GB, respectively. That is fine.

6.png

I would like to know what happens to the free area (17 GB)? Is that accessible for other VMs? Is that a shared region?

Also, what is the ballooned memory which is 0 (black line)?

Reply
0 Kudos
scott28tt
VMware Employee
VMware Employee

There are some great references on memory management here:

Memory Virtualization Basics

Administering Memory Resources

They should help you understand more.


-------------------------------------------------------------------------------------------------------------------------------------------------------------

Although I am a VMware employee I contribute to VMware Communities voluntarily (ie. not in any official capacity)
VMware Training & Certification blog
Reply
0 Kudos
Ardaneh
Enthusiast
Enthusiast

Good question!

When we are talking about Memory or CPU in the virtualized world, we are talking about shared resources, so for instance when you assigned 12 GB of memory (Granted Memory) to a VM (If you don't reserve the allocated memory to the VM) it uses the memory by its needs (Active Memory) and the free part of the memory (for example 8 GB of 12 GB) will be used by other VMs until the total amount of your ESXi host memory reaches the low or soft state (you can check your ESXi memory state by using esxtop command - M switch).

When this situation occurred, some algorithms will run to provide enough memory for those VMs that are in contention, one of those algorithms is Memory Ballooning. with Ballooning, those parts of VM memory (In guest os level) with the free flag will be restored to the ESXi (using a driver called "vmmemctl" that was installed by VMware tools) and then ESXi can serve other VMs.

Hence, memory ballooning is not a good sign for your virtualization, so you should keep it to zero as long as you can (by avoiding memory overcommitment)

Hope this could be helpful