Bug 1070746

Summary: Cannot rename VM if it has some associated snapshots
Product: [Fedora] Fedora Reporter: Tomáš Hozza <thozza>
Component: virt-managerAssignee: Cole Robinson <crobinso>
Status: CLOSED DUPLICATE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 20CC: berrange, crobinso, virt-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: 2014-02-27 14:11:57 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:

Description Tomáš Hozza 2014-02-27 13:45:25 UTC
Description of problem:
In F20, the default image format is qcow2 which allows user to create snapshots
of the VM. If you install a VM using virt-manager and create some snapshots,
you are not able to rename the VM.

The error message printed does not makes sense to me as a USER!

"Error changing VM configuration: Requested operation is not valid: cannot delete inactive domain with 2 snapshots"

I just renamed the VM and clicked apply. I as a user don't care what 
virt-manager is doing under the hood and should not be confronted with the 
internal process like "cannot delete inactive domain with 2 snapshots".


Version-Release number of selected component (if applicable):
virt-manager-0.10.0-5.git1ffcc0cc.fc20.noarch

How reproducible:


Steps to Reproduce:
1. install VM using virt-manager
2. create VM snapshots using virt-manager
3. try to rename the VM

Actual results:
you are not able to do it

Expected results:
I should be able to rename the VM regardless if it has any snapshots!

Additional info:
Error changing VM configuration: Requested operation is not valid: cannot delete inactive domain with 2 snapshots

Traceback (most recent call last):
  File "/usr/share/virt-manager/virtManager/details.py", line 2409, in _change_config_helper
    func(*args)
  File "/usr/share/virt-manager/virtManager/domain.py", line 461, in define_name
    newname)
  File "/usr/share/virt-manager/virtManager/libvirtobject.py", line 87, in _define_name_helper
    rename_cb(self, origxml, newxml)
  File "/usr/share/virt-manager/virtManager/connection.py", line 782, in rename_vm
    obj, origxml, newxml)
  File "/usr/share/virt-manager/virtManager/connection.py", line 753, in _rename_helper
    obj.delete(force=False)
  File "/usr/share/virt-manager/virtManager/domain.py", line 1278, in delete
    self._backend.undefine()
  File "/usr/lib64/python2.7/site-packages/libvirt.py", line 1866, in undefine
    if ret == -1: raise libvirtError ('virDomainUndefine() failed', dom=self)
libvirtError: Requested operation is not valid: cannot delete inactive domain with 2 snapshots

Comment 1 Cole Robinson 2014-02-27 14:11:57 UTC

*** This bug has been marked as a duplicate of bug 558160 ***