Red Hat Bugzilla – Bug 823160
api: host statistics: memory.free value is wrong
Last modified: 2012-06-21 04:34:59 EDT
Description of problem:
Memory host statistics in api don't add-up correctly.
The "memory.free" value seem to be wrong (after comparing the numbers with the ones shown in admin GUI).
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1. under root api URL, navigate to: hosts/<host-GUID>/statistics
2. check the memory.total, memory.used, memory.free values
numbers don't add up (memory.used + memory.free <> memory.total)
numbers add up (memory.used + memory.free = memory.total)
in api, memory.free is calculated as:
So VDS.getmem_available() doesn't seem to represent the Host's free memory (not sure if by design or due to a bug).
The engine's "Host.getmem_available()" probably reflects the vdsm's "memAvailable" value returned from the "getVdsStats" vdsm api verb.
So bug is in either rest-api, engine-core or vdsm.
*** This bug has been marked as a duplicate of bug 826643 ***