Bug 823160

Summary: api: host statistics: memory.free value is wrong
Product: [Retired] oVirt Reporter: Einav Cohen <ecohen>
Component: ovirt-engine-apiAssignee: Ori Liel <oliel>
Status: CLOSED DUPLICATE QA Contact:
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: unspecifiedCC: acathrow, dyasny, iheim, mgoldboi, pablo.iranzo, ykaul
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard: infra
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-06-21 08:34:59 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Einav Cohen 2012-05-19 15:39:28 UTC
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):
oVirt upstream

How reproducible:
always

Steps to Reproduce:
1. under root api URL, navigate to: hosts/<host-GUID>/statistics
2. check the memory.total, memory.used, memory.free values
  
Actual results:
numbers don't add up (memory.used + memory.free <> memory.total)

Expected results:
numbers add up (memory.used + memory.free = memory.total)

Additional info:
in api, memory.free is calculated as:
VDS.getmem_available()

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.

Comment 1 Ori Liel 2012-06-21 08:34:59 UTC

*** This bug has been marked as a duplicate of bug 826643 ***