Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.
Bug 989797 - pmchart CPU view shows both User and Guest, but User CPU time includes Guest
Summary: pmchart CPU view shows both User and Guest, but User CPU time includes Guest
Alias: None
Product: Fedora
Classification: Fedora
Component: pcp
Version: 19
Hardware: Unspecified
OS: Unspecified
Target Milestone: ---
Assignee: Nathan Scott
QA Contact: Fedora Extras Quality Assurance
Depends On:
TreeView+ depends on / blocked
Reported: 2013-07-30 01:19 UTC by Mark Goodwin
Modified: 2015-01-28 03:51 UTC (History)
7 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Last Closed: 2015-01-28 03:51:20 UTC

Attachments (Terms of Use)

Description Mark Goodwin 2013-07-30 01:19:21 UTC
Description of problem: pmchart CPU view shows both User and Guest, but the CPU accounting code in the kernel double counts Guest CPU time as User CPU time too, so displaying both User and Guest is incorrect.

Version-Release number of selected component (if applicable): pcp-gui-1.5.9-1

How reproducible: always

Steps to Reproduce:
1. pmchart -c CPU
2. fire up a VM and burn some CPU time in it

Actual results: CPU charts (as a stacked bar) exceed NCPUs * 100%

Expected results: user cpu time should not include guest CPU time in the charts

Additional info: unfortunately the kernel CPU accounting double counts guest as user CPU time. To fix this I think we'll need a new metric, e.g. kernel.*.cpu.vuser (or some such name) that subtracts guest CPU time from user CPU time, accounting for counter wrapping and so forth. I don't think we can change the semantics of the existing kernel.*.cpu.user metric. We'll probably need a different CPU view variant for pmchart too, e.g. "HypervisorCPU" or something.

Comment 1 Mark Goodwin 2013-07-30 03:33:06 UTC
since I added Guest to the CPU view, I'll follow-thru with fixing this up. This BZ was posted for RFC reasons mostly. The main change will be in the Linux PMDA to add the new metric. Any RFC comments welcome.

Comment 2 Nathan Scott 2013-07-30 03:38:52 UTC
No RFC comments, just cheering from the side-lines - thanks for taking this on.

Comment 3 Mark Goodwin 2014-06-13 06:44:07 UTC
upstream commit finished this off 

commit 37f48043a79bb716dab62d7687aaff70376e5198
Author: Mark Goodwin <>
Date:   Fri Jun 13 16:11:38 2014 +1000

    Remove Guest from the standard CPU view since User (kernel.all.cpu.user)
    includes Guest. Create a new view called vCPU that includes Guest and vUSER,
    where vUSER is kernel.all.cpu.vuser which does not include Guest.

        modified:   src/pmchart/views/CPU
        new file:   src/pmchart/views/vCPU

Comment 4 Fedora Admin XMLRPC Client 2014-06-26 06:44:38 UTC
This package has changed ownership in the Fedora Package Database.  Reassigning to the new owner of this component.

Comment 5 Fedora End Of Life 2015-01-09 19:09:35 UTC
This message is a notice that Fedora 19 is now at end of life. Fedora 
has stopped maintaining and issuing updates for Fedora 19. It is 
Fedora's policy to close all bug reports from releases that are no 
longer maintained. Approximately 4 (four) weeks from now this bug will
be closed as EOL if it remains open with a Fedora 'version' of '19'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora 19 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora, you are encouraged  change the 'version' to a later Fedora 
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

Comment 6 Nathan Scott 2015-01-28 03:51:20 UTC
Fixed by mgoodwin, as per earlier comment.

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