On Tue, Mar 08, 2016 at 12:12:45PM +0000, suyog jadhav wrote:
How to measure memory utilizatin of guest when dommemstat reports
"RSS" is more than "ACTUAL"?
Following is the output on RHEL 6.6
# dommemstat 1
actual 16777216
rss 16890372
# dommemstat 2
actual 16777216
rss 16460516
I found following article on Redhat which suggests that this is normal/expected?
https://access.redhat.com/solutions/2017943
And that link explains everything you are asking for here.
Now we use following formula to calculate the memory utilization.
mem_util = (rss/actual)*100
now this gives more that 100% as the result.
We use the libvirt library to call the virDomainMemoryStats. (which is the same used by
the "virsh dommemstat" command)
If we can't use the RSS as the "used memory", what else should be used to
calculate the same?
What is the ideal approach to report memory utilization of guest from the KVM host?
It depends what do you mean by "used memory". The memory the process
uses? Yes, you can use RSS. The memory that's actually being used in
the guest? No, you can't use it, that's not relevant. How much of the
memory is not being occupied by the balloon? No, you cannot use RSS for
that. There are many scenarios to this. Check how libvirt (and
possibly qemu) works regarding memory allocations etc. in case you need
more info about what which domain does/uses.
_______________________________________________
libvirt-users mailing list
libvirt-users(a)redhat.com
https://www.redhat.com/mailman/listinfo/libvirt-users