Bug 797281

Summary: libvirt deletes VM configuration file after edit
Product: [Community] Virtualization Tools Reporter: Shevek <bugzilla>
Component: libvirtAssignee: Libvirt Maintainers <libvirt-maint>
Status: CLOSED INSUFFICIENT_DATA QA Contact:
Severity: high Docs Contact:
Priority: unspecified    
Version: unspecifiedCC: crobinso, xen-maint
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-03-23 20:47:21 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Shevek 2012-02-24 18:45:01 UTC
Description of problem:

libvirt deleted the XML configuration file for a VM after an edit.

Version-Release number of selected component (if applicable):

ii  libvirt-bin                     0.9.2-4ubuntu15                            ii  libvirt0                        0.9.2-4ubuntu15                            

How reproducible: 100%

Steps to Reproduce:
1. Create and define a VM, but do not start it.
2. virsh edit the VM.
3. Change the UUID
4. Save and exit the editor.
5. Error message appears:
error: operation failed: domain 'orchestra' already exists with uuid 4dd4e4bc-ec46-d7b8-5935-cbd727dd89c0
6. Observe XML file in /etc/libvirt/qemu now gone, and never called me mother.
  
Actual results:
XML file vanished, and VM config lost to posterity.

Expected results:
VM config should still exist, with an updated UUID.
libvirt should honour the updated UUID.

Comment 1 Dave Allan 2012-02-24 19:48:07 UTC
Hmm, I tried your steps to reproduce, but I am unable to reproduce this behavior on libvirt 0.9.6.  I see the message about domain already exists with uuid..., but the VM is unaffected following the attempt to edit it.  What version of libvirt are you using?