RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 844266 - Fail to modify the domain xml with saved file
Summary: Fail to modify the domain xml with saved file
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: libvirt
Version: 6.4
Hardware: x86_64
OS: Linux
medium
medium
Target Milestone: rc
: ---
Assignee: Ján Tomko
QA Contact: Virtualization Bugs
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-07-30 07:23 UTC by zhenfeng wang
Modified: 2013-02-21 07:20 UTC (History)
9 users (show)

Fixed In Version: libvirt-0.10.0-0rc1.el6
Doc Type: Bug Fix
Doc Text:
Cause: The condition checking if the save image XML change was successful was inverted. Consequence: Virsh said it failed when it was successful and vice versa. Fix: Invert the condition. Result: Success and failure get reported correctly.
Clone Of:
Environment:
Last Closed: 2013-02-21 07:20:21 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2013:0276 0 normal SHIPPED_LIVE Moderate: libvirt security, bug fix, and enhancement update 2013-02-20 21:18:26 UTC

Description zhenfeng wang 2012-07-30 07:23:42 UTC
Description of problem:
It reported "saved fail" when i modified the domain xml with saved file,but actually ,it saved successully

Version-Release number of selected component (if applicable):
# rpm -qa|grep libvirt
 libvirt-python-0.9.13-3.el6.x86_64
 libvirt-0.9.13-3.el6.x86_64
 libvirt-client-0.9.13-3.el6.x86_64
 libvirt-docs-0.9.13-2.el6.x86_64
 libvirt-devel-0.9.13-3.el6.x86_64
 qemu-kvm-rhev-0.12.1.2-2.299.el6.x86_64
# uname -r
 2.6.32-293.el6.x86_64
How reproducible:
100%

Steps to Reproduce:
1.# virsh save-image-edit rhel6-qcow2.save
 ..snip...

 <on_poweroff>destroy</on_poweroff>
 <on_reboot>restart</on_reboot>
 <on_crash>restart</on_crash>
 ..snip...

Edit the xml:
 Update "<on_crash>restart</on_crash>" to"<on_crash>destroy</on_crash>"

2.Then save,it reported:
 # virsh save-image-edit rhel6-qcow2.save 
 Failed. Try again? [y,n,f,?]:n

3.# virsh restore rhel6-qcow2.save
 Domain restored from rhel6-qcow2.save

# virsh dumpxml rhel6-qcow2

 ..snip...
 <on_poweroff>destroy</on_poweroff>
 <on_reboot>restart</on_reboot>
 <on_crash>destroy</on_crash>
 ..snip...
  
Actual results:
when modify the xml, it saved successfully ,but reported " saved fail" error information

Expected results:
when modify the xml,it saved successfully and no reporting error information

Additional info:

Comment 3 Ján Tomko 2012-08-10 13:22:23 UTC
Upstream patch proposed:

https://www.redhat.com/archives/libvir-list/2012-August/msg00688.html

Comment 4 Ján Tomko 2012-08-14 07:56:57 UTC
Fixed by commit 863399f06b8dad8d7fc2e4b962d3cc566b69ed4c
    virsh: say save-image-edit failed only when it does

Comment 7 hongming 2012-08-27 02:10:30 UTC
Verified it using libvirt-0.10.0-0rc1.el6.x86_64. The result is expected. So move its status to VERIFIED.



Steps

1. # virsh save-image-edit rhel6.save

Edit the xml:
 Update "<on_crash>restart</on_crash>" to"<on_crash>destroy</on_crash>"

2. Save it .

State file rhel6.save edited.


3. # virsh restore rhel6.save
Domain restored from rhel6.save


4. # virsh dumpxml rhel6
......
  <on_crash>destroy</on_crash>
......

Comment 8 errata-xmlrpc 2013-02-21 07:20:21 UTC
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.

http://rhn.redhat.com/errata/RHSA-2013-0276.html


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