Bug 1468634 - Incorrect Max CPU and Memory usage values displayed
Incorrect Max CPU and Memory usage values displayed
Product: Red Hat CloudForms Management Engine
Classification: Red Hat
Component: C&U Capacity and Utilization (Show other bugs)
All All
high Severity medium
: GA
: 5.9.0
Assigned To: James Wong
Tasos Papaioannou
Depends On:
  Show dependency treegraph
Reported: 2017-07-07 11:18 EDT by Tasos Papaioannou
Modified: 2018-03-01 08:14 EST (History)
6 users (show)

See Also:
Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2018-03-01 08:14:47 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Tasos Papaioannou 2017-07-07 11:18:12 EDT
Description of problem:

The Max values displayed for CPU and CPU Usage, and for Memory and Memory usage, are inconsistent with each other. For example, a VM with seven daily metric rollup records shows the following under Normal Operating Ranges:

Max	46.29 MHz
High	42.20 MHz
Average	37.29 MHz
Low	32.38 MHz

CPU Usage 	  	 
Max	55.99%
High	2.53%
Average	1.47%
Low	0.40%

Max	69.01 MB
High	69.19 MB
Average	66.85 MB
Low	64.5 MB

Memory Usage  	 
Max	14.99%
High	2.57%
Average	2.31%
Low	2.06%

The max CPU Usage value (55.99%) is found by taking the highest maximum realtime cpu usage value (min_max[:abs_max_cpu_usage_rate_average_value]) from all of the daily metric rollups. This value is ~38 times greater than the Average CPU Usage value (1.47%), yet the corresponding Max and Average CPU (MHz) values differ only by a factor of ~1.24 times. It looks like the Max CPU value is actually being taken from the max value of cpu_usagemhz_rate_average:

vmdb_production=# select max(cpu_usagemhz_rate_average) from metric_rollups where capture_interval_name='daily' and resource_id=636;
(1 row)

This is showing the maximum of the daily averages, not the realtime maximum. The same discrepancy can be seen for the Max value under Memory and Memory Usage.

Version-Release number of selected component (if applicable):

How reproducible:


Steps to Reproduce:
1.) Gather one or more days' worth of C&U data for a VM.
2.) View Normal Operating Ranges data for the VM in the web UI.

Actual results:

Inconsistent Max values shown for CPU/CPU Usage and for Memory/Memory Usage.

Expected results:

The Max values displayed for CPU MHz and Memory MB should be consistent with the Max values for CPU Usage and Memory Usage. Either they should both display the all-time realtime max values, or they should both display the max daily average values.

Additional info:
Comment 6 James Wong 2017-10-19 09:33:58 EDT
The fix for CPU is merged: https://github.com/ManageIQ/manageiq/pull/16195

The fix for memory is being reviewed: https://github.com/ManageIQ/manageiq/pull/16224
Comment 7 James Wong 2017-11-15 13:10:11 EST
Both PRs are merged.
Comment 8 Tasos Papaioannou 2017-11-21 14:36:02 EST
Verified on
Comment 11 errata-xmlrpc 2018-03-01 08:14:47 EST
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.


Note You need to log in before you can comment on or make changes to this bug.