Bug 534143 - virsh save corrupts image
virsh save corrupts image
Status: CLOSED ERRATA
Product: Fedora
Classification: Fedora
Component: libvirt (Show other bugs)
12
x86_64 Linux
high Severity medium
: ---
: ---
Assigned To: Daniel Berrange
Fedora Extras Quality Assurance
:
: 533306 (view as bug list)
Depends On:
Blocks: F12VirtTarget
  Show dependency treegraph
 
Reported: 2009-11-10 13:04 EST by David
Modified: 2010-05-28 13:56 EDT (History)
9 users (show)

See Also:
Fixed In Version: libvirt-0.7.1-16.fc12
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2010-05-28 13:56:33 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


Attachments (Terms of Use)
log for the vm in /var/log/libvirt/qemu (1015 bytes, text/plain)
2009-11-10 13:05 EST, David
no flags Details
Fix save & restore with unprivileged guests, and SELinux (6.43 KB, patch)
2009-11-11 07:40 EST, Daniel Berrange
no flags Details | Diff

  None (edit)
Description David 2009-11-10 13:04:34 EST
Description of problem:
I create a VM using virsh create, and then I save the image using virsh save. When I try to use virsh restore, I get an error:

error: Failed to restore domain from /aml/images/pr104.img
error: internal error Timed out while reading monitor startup output

/var/log/messages had the following error message:
error : qemudReadMonitorOutput:827 : internal error Timed out while reading monitor startup output


I will attach the /var/log/libvirt/qemu/pr104.log file. 

Version-Release number of selected component (if applicable):
fedora 12 beta
libvirt version 0.7.1
qemu-kvm version 0.11.0

How reproducible:
all the time. 

Steps to Reproduce:
1. virsh create on some xml file.
2. virsh save image
3. virsh restore image
  
Actual results:
virsh times out and the restore fails

Expected results:
the image to be restored to memory.


Additional info:
Comment 1 David 2009-11-10 13:05:46 EST
Created attachment 368449 [details]
log for the vm in /var/log/libvirt/qemu
Comment 2 David 2009-11-10 13:28:59 EST
*** Bug 533306 has been marked as a duplicate of this bug. ***
Comment 3 David 2009-11-10 13:30:48 EST
I created a workaround for this bug by editing /etc/libvirt/qemu.conf and uncommenting the lines "user = "root"" and "group = "root"".
Comment 4 Daniel Berrange 2009-11-11 07:38:55 EST
Fixing product since this is reporting Fedora RPM version.
Comment 5 Daniel Berrange 2009-11-11 07:40:24 EST
Created attachment 369015 [details]
Fix save & restore with unprivileged guests, and SELinux 

When running qemu:///system instance, libvirtd runs as root, but QEMU may
optionally be configured to run non-root. When then saving a guest to a state
file, the file is initially created as root, and thus QEMU cannot write to it.
It is also missing labelling required to allow access via SELinux. This patch
fixes those issues.

http://www.redhat.com/archives/libvir-list/2009-November/msg00376.html
Comment 6 Mark McLoughlin 2009-11-19 07:39:57 EST
See also bug #532654
Comment 7 Fedora Update System 2010-05-18 12:55:45 EDT
libvirt-0.7.1-16.fc12 has been submitted as an update for Fedora 12.
http://admin.fedoraproject.org/updates/libvirt-0.7.1-16.fc12
Comment 8 Fedora Update System 2010-05-19 15:13:44 EDT
libvirt-0.7.1-16.fc12 has been pushed to the Fedora 12 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update libvirt'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/libvirt-0.7.1-16.fc12
Comment 9 Fedora Update System 2010-05-28 13:55:58 EDT
libvirt-0.7.1-16.fc12 has been pushed to the Fedora 12 stable repository.  If problems still persist, please make note of it in this bug report.

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