Bug 1696016

Summary: The 'Memory - Avg Used' in CloudForms includes cached memory with the used memory of OpenStack instance
Product: Red Hat CloudForms Management Engine Reporter: Nikhil Gupta <ngupta>
Component: ProvidersAssignee: Sam Lucidi <slucidi>
Status: CLOSED CANTFIX QA Contact: Ido Ovadia <iovadia>
Severity: medium Docs Contact: Red Hat CloudForms Documentation <cloudforms-docs>
Priority: medium    
Version: 5.10.2CC: dmetzger, jfrey, jhardy, jocarter, jprause, maufart, mfeifer, mshriver, obarenbo, slucidi, smallamp
Target Milestone: GAFlags: mfeifer: mirror+
Target Release: 5.10.12   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2019-09-25 15:11:02 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: Openstack Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1704905    

Description Nikhil Gupta 2019-04-04 02:59:05 UTC
Description of problem:

When running a report with "Memory - Avg Used for Collected Intervals 30 Day Avg (MB)" field, it reports cached memory with the used memory.

We are looking at a specific instance, which has total memory 20,480 MB.  The report for that collected value is 17,658.  This would indicate that used system memory has been about 86% over the last 30 days.  When I look at Nagios dashboard graph and ELK monitoring graph results of memory for the same instance over the last 30 days, I am seeing a peak of about 70% memory usage.  This does not include cache or buffer memory (which would put it closer to 100%).

It looks like if I include cached memory with the used memory (and not counting buffer memory), that puts me close to what CloudForms is reporting.  

Are there any memory values returned from RHOSP queries that would return actual used memory or even just cached memory so as to figure out actual usage?

Version-Release number of selected component (if applicable):
cfme-5.10.2
RHOSP 13 

How reproducible:
Always

Steps to Reproduce:
1. Create VMs and Instances report
2. Add "Name" and "Memory - Avg Used for Collected Intervals 30 Day Avg (MB)" field
3. Run

Actual results:
Reports cached memory with the used memory.

Expected results:
Should report only the actual used memory.

Additional info:
Following bug reported for OpenStack provider in the past:
https://bugzilla.redhat.com/show_bug.cgi?id=1425951

It has been fixed for OpenStack infra provider (Under Cloud):
/opt/rh/cfme-gemset/bundler/gems/cfme-providers-openstack-a277948eff1f/app/models/manageiq/providers/openstack/infra_manager/metrics_capture.rb

However, it is not included in OpenStack cloud provider (Over Cloud):
/opt/rh/cfme-gemset/bundler/gems/cfme-providers-openstack-a277948eff1f/app/models/manageiq/providers/openstack/cloud_manager/metrics_capture.rb

Comment 9 dmetzger 2019-09-25 13:09:46 UTC
Based on comment #6, should this ticket be closed or is further investigation required?