Bug 601692

Summary: RFE virtio balloon driver does not include extended memory statistics
Product: Red Hat Enterprise Linux 5 Reporter: Daniel Berrangé <berrange>
Component: kernelAssignee: Amit Shah <amit.shah>
Status: CLOSED ERRATA QA Contact: Red Hat Kernel QE team <kernel-qe>
Severity: medium Docs Contact:
Priority: low    
Version: 5.6CC: bugproxy, mjenner, tburke, virt-maint
Target Milestone: rcKeywords: FutureFeature
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Enhancement
Doc Text:
Story Points: ---
Clone Of: 601690 Environment:
Last Closed: 2011-01-13 21:36:18 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 531800, 557597, 571528, 580949, 600363    

Description Daniel Berrangé 2010-06-08 13:30:46 UTC
+++ This bug was initially created as a clone of Bug #601690 +++

Description of problem:
KVM and libvirt in RHEL6 have support for querying extended memory statistics from the guest kernel balloon driver. The RHEL6 kernel, however, is missing this since IIRC it was only added in 2.6.34. This is causing frequent bug reports from beta testers expecting extended statistics to be present in RHEL6 and is also useful information for host admins. The code is well isolated from the rest of the kernel, so it should be feasible to backport this.


Version-Release number of selected component (if applicable):
kernel-2.6.32-33.el6
libvirt-0.8.1-7.el6.x86_64
qemu-kvm-0.12.1.2-2.50.el6.x86_64

How reproducible:
Always

Steps to Reproduce:
1. Boot a RHEL6 KVM guest
2. Run 'virsh dommemstat $GUESTNAME' on the host
3.
  
Actual results:
No output

Expected results:
Similar output to

# virsh dommemstat f14x86_64
swap_in 0
swap_out 0
major_fault 1421
minor_fault 5607546
unused 26672
available 794344



Additional info:
There appear to be at least 3 upstream patches required to provide this support in the kernel virtio balloon driver.

http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=9564e138b1f6eb137f7149772438d3f3fb3277dd
http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=1f34c71afe5115e77a49c4e67720a66e27053e54
http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=169c246a30808588436794e96a97c61a01af9bed

Comment 1 Amit Shah 2010-06-11 10:26:17 UTC
The virtio balloon code in RHEL5 is slightly stale. For getting these patches, we'll also have to either backport other patches (which add new features). Is that desirable for RHEL5?

Comment 2 Amit Shah 2010-08-31 03:39:05 UTC
(In reply to comment #1)
> The virtio balloon code in RHEL5 is slightly stale. For getting these patches,
> we'll also have to either backport other patches (which add new features). Is
> that desirable for RHEL5?

Answering my own question: the same changes (in the common virtio code) were needed by the backport for virtio-console as well, and those changes are now in the RHEL5 tree.

Only the balloon-specific changes now need to be backported, which are a clean backport from upstream for the commits mentioned in the original report. I'm building the kernel and will post patches soon.

Comment 4 Amit Shah 2010-09-02 05:13:05 UTC
Note to QE: the stats enabled here won't be shown due to reverting the functionality as part of bug 623903. If you wish to test this functionality, use a RHEL6 host with a qemu-kvm build < qemu-kvm-0.12.1.2-2.113.el6.

Comment 10 John Jarvis 2010-09-08 13:36:30 UTC
*** Bug 563588 has been marked as a duplicate of this bug. ***

Comment 11 Jarod Wilson 2010-09-10 21:40:05 UTC
in kernel-2.6.18-219.el5
You can download this test kernel from http://people.redhat.com/jwilson/el5

Detailed testing feedback is always welcomed.

Comment 15 errata-xmlrpc 2011-01-13 21:36:18 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHSA-2011-0017.html