Jump to content


The problem with xapi daemon metrics in monitoring XenServer performance

Started by CH Liao , 15 January 2014 - 11:51 AM
1 reply to this topic

CH Liao Members

CH Liao
  • 2 posts

Posted 15 January 2014 - 11:51 AM



     In xenserver administrator's guide, there are 4 xapi demon metric can be query by RRD



xapi_allocation_kib Memory (KiB) allocation done by the xapi daemon. Enabled by default. Agent Memory Allocation

xapi_free_memory_kib Free memory (KiB) available to the xapi daemon. Enabled by default. Agent Memory Free      

xapi_live_memory_kib Live memory (KiB) used by xapi daemon. Enabled by default. Agent Memory Live

xapi_memory_usage_kib Total memory (KiB) allocated used by xapi daemon. Enabled by default. Agent Memory Usage



but, I don't know what the detailed means of them, 


when I used 'top' command to look up xapi deamon memory, there is a big difference between them.


I tried to add loading to xapi, the 'xapi_allocation_kib' is increase, but 'xapi_free_memory_kib' 'xapi_live_memory_kib' 'xapi_memory_usage_kib' are not change a lot.


So, How do I interpret these metric?


Please help



Rachel Berry Citrix Employees

Rachel Berry
  • 597 posts

Posted 16 June 2014 - 10:27 PM

These are the sources of the definitions, a bit hidden I guess:

* rrd tag to xapi's tag:
* xapi's tag to ocaml's gcc tag:

So, these values are basically returning what the ocaml garbage collector understands, as in:

* xapi_allocation_kib: how much xapi's gc heap memory xapi has used so far (this is an internal gc metric that indicates how much memory xapi asked the gc to allocate since xapi started)
* xapi_free_memory_kib: how much of xapi's gc heap is available currently to xapi
* xapi_live_memory_kib: how much of xapi's gc heap is being used currently by xapi
* xapi_memory_usage_kib: how much dom0 memory xapi's gc heap is using currently (ie, size of the xapi's gc heap)

However, Our engineers believe there's a bug in here since Tampa, when the rrd daemon was disaggregated from xapi. As you can see from the source code above, this gc data is being collected from the rrd daemon process' gc heap, instead of the xapi process' gc heap. That would explain why you can't correlate the rrd data you see with the xapi process. An internal ticket is tracking this case CA-137766 to verify if this is the case. Thank you for raising the issue. We will look at better documentation.

Many thanks for your time raising this issue and lack of documentation.