public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
From: bugzilla-daemon@bugzilla.kernel.org
To: kvm@vger.kernel.org
Subject: [Bug 55061] New: cpu stats reported in cgroup file is erroneous
Date: Sun, 10 Mar 2013 16:14:59 +0000 (UTC)	[thread overview]
Message-ID: <bug-55061-28872@https.bugzilla.kernel.org/> (raw)

https://bugzilla.kernel.org/show_bug.cgi?id=55061

           Summary: cpu stats reported in cgroup file is erroneous
           Product: Virtualization
           Version: unspecified
    Kernel Version: 3.5.3-1.fc17.i686.PAE
          Platform: All
        OS/Version: Linux
              Tree: Mainline
            Status: NEW
          Severity: high
          Priority: P1
         Component: kvm
        AssignedTo: virtualization_kvm@kernel-bugs.osdl.org
        ReportedBy: roopagovind@yahoo.com
        Regression: No


While testing the virsh cpu-stats functionality, I found that the stats
reported in the command output is incorrect, specifically the reported user
time and system time.

Please find a sample output.

virsh cpu-stats fedora-18 --total --start 0 --count 4
CPU0:
    cpu_time            15.321903938 seconds
CPU1:
    cpu_time            11.410812819 seconds
CPU2:
    cpu_time             2.948269295 seconds
CPU3:
    cpu_time             1.724287630 seconds
Total:
    cpu_time            31.405273682 seconds
    user_time            1.310000000 seconds
    system_time         12.860000000 seconds


As you can see here, the user time is less than system_time which is incorrect.
As an experiment, I tried running a while 1 loop inside this guest and observed
that stats for a period of time was not changing appropriately or rather not
the expected way.

While the while 1 loop was running inside the guest, the user_time continued to
be less than system_time which is incorrect. More over the guest is not running
any workload expect this while 1 loop.

So definitely there seems to be a bug in the cgroup accounting of cpu stats.
Please fix this cgroup bug.

I've verified this against different distro versions and flavors and hit the
same issue across all these test environments.

--roopa

-- 
Configure bugmail: https://bugzilla.kernel.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching the assignee of the bug.

             reply	other threads:[~2013-03-10 16:15 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-03-10 16:14 bugzilla-daemon [this message]
2013-03-23 11:22 ` [Bug 55061] cpu stats reported in cgroup file is erroneous bugzilla-daemon
2013-03-26 17:24 ` bugzilla-daemon
2013-03-26 17:28 ` bugzilla-daemon

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=bug-55061-28872@https.bugzilla.kernel.org/ \
    --to=bugzilla-daemon@bugzilla.kernel.org \
    --cc=kvm@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox