Bug 911997

Summary: memtune did not live update domain xml
Product: Red Hat Enterprise Linux 6 Reporter: Wayne Sun <gsun>
Component: libvirtAssignee: John Ferlan <jferlan>
Status: CLOSED WONTFIX QA Contact: Virtualization Bugs <virt-bugs>
Severity: medium Docs Contact:
Priority: high    
Version: 6.4CC: acathrow, cwei, dallan, dyuan, honzhang, mzhan, shyu
Target Milestone: rcKeywords: Upstream
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
: 911998 1045448 (view as bug list) Environment:
Last Closed: 2014-04-04 20:58:52 UTC Type: Bug
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: 911998    

Description Wayne Sun 2013-02-17 06:39:39 UTC
Description of problem:
When tuning memory parameters at domain shutoff, config xml is updated with <memtune> part, but when live tuning domain memory parameters, setting is done without live update domain xml. 

Version-Release number of selected component (if applicable):
libvirt-0.10.2-18.el6.x86_64
qemu-kvm-rhev-0.12.1.2-2.352.el6.x86_64
kernel-2.6.32-356.el6.x86_64

How reproducible:
always

Steps to Reproduce:
1. tuning memory parameter when domain is shut off
# virsh destroy libvirt_test_api
Domain libvirt_test_api destroyed

# virsh memtune libvirt_test_api --swap-hard-limit -1 --soft-limit -1

# virsh memtune libvirt_test_api --config
hard_limit     : 0
soft_limit     : unlimited
swap_hard_limit: unlimited

# virsh dumpxml libvirt_test_api
...
  <memtune>
    <soft_limit unit='KiB'>9007199254740991</soft_limit>
    <swap_hard_limit unit='KiB'>9007199254740991</swap_hard_limit>
  </memtune>
...

2. tuning memory parameter when domain is on
# virsh start libvirt_test_api
Domain libvirt_test_api started

# virsh memtune libvirt_test_api --live
hard_limit     : 25417216
soft_limit     : unlimited
swap_hard_limit: unlimited

# virsh memtune libvirt_test_api --swap-hard-limit 25417216000 --soft-limit 2541721600 --live

# virsh memtune libvirt_test_api --live
hard_limit     : 25417216
soft_limit     : 2541721600
swap_hard_limit: 25417216000

# virsh dumpxml libvirt_test_api
...
  <memtune>
    <soft_limit unit='KiB'>9007199254740991</soft_limit>
    <swap_hard_limit unit='KiB'>9007199254740991</swap_hard_limit>
  </memtune>
...

live update did not update the domain xml, it remains as set when domain is off. 
  
Actual results:
memtune did not live update domain xml 

Expected results:
memtune should live update domain xml 

Additional info:

Comment 2 Gunannan Ren 2013-04-18 12:32:05 UTC
commit 0047d5d6e86cf84e71b2503c3939fc97c3ffe8b9
Author: Guannan Ren <gren>
Date:   Wed Mar 6 00:24:57 2013 +0800

    qemu: update domain live xml for virsh memtune with --live flag
    
    virsh subcommand memtune forgot updating domain live xml
    after setting cgroup value.

Comment 3 Jiri Denemark 2013-06-11 10:05:49 UTC
We decided not to rebase libvirt in RHEL 6.5 to avoid stability issues
we faced in 6.4. This bug has already been trivially fixed upstream but
it is not considered important enough to be backported to RHEL 6.5.

Thus I'm pushing this bug to RHEL 6.6 (and setting Upstream keyword to
indicate we have patches upstream) for now. If you don't agree with
this resolution, please, give us reasons which you think are strong
enough for us to reevaluate the decision not to backport patches for
this bug.

Comment 6 RHEL Program Management 2014-04-04 20:58:52 UTC
Development Management has reviewed and declined this request.
You may appeal this decision by reopening this request.