Bug 1265697 - Problems with renaming of UEFI VMs
Problems with renaming of UEFI VMs
Status: CLOSED ERRATA
Product: Fedora
Classification: Fedora
Component: virt-manager (Show other bugs)
24
Unspecified Linux
unspecified Severity unspecified
: ---
: ---
Assigned To: Cole Robinson
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2015-09-23 09:46 EDT by Jiri Konecny
Modified: 2017-05-12 15:21 EDT (History)
4 users (show)

See Also:
Fixed In Version: virt-manager-1.4.1-2.fc24
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2017-05-12 15:21:59 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Jiri Konecny 2015-09-23 09:46:01 EDT
Description of problem:
When I'm trying to change name of the existing VM with UEFI I got this traceback:

Error apply changes: Requested operation is not valid: cannot delete inactive domain with nvram

Traceback (most recent call last):
  File "/usr/share/virt-manager/virtManager/details.py", line 1948, in config_apply
    ret = self.config_overview_apply()
  File "/usr/share/virt-manager/virtManager/details.py", line 2040, in config_overview_apply
    self.vm.define_name(self.widget("overview-name").get_text())
  File "/usr/share/virt-manager/virtManager/libvirtobject.py", line 129, in define_name
    self.conn.rename_object(self, origxml, newxml, oldname, newname)
  File "/usr/share/virt-manager/virtManager/connection.py", line 668, in rename_object
    obj.delete(force=False)
  File "/usr/share/virt-manager/virtManager/libvirtobject.py", line 83, in newfn
    ret = fn(self, *args, **kwargs)
  File "/usr/share/virt-manager/virtManager/domain.py", line 1444, in delete
    self._backend.undefine()
  File "/usr/lib64/python2.7/site-packages/libvirt.py", line 2602, in undefine
    if ret == -1: raise libvirtError ('virDomainUndefine() failed', dom=self)
libvirtError: Requested operation is not valid: cannot delete inactive domain with nvram

--------------------
There is another issue. When I tried to reproduce this I could create new VM (name generic-2) and without installation rename it (to jk_efi) but when I removed this VM and create another with the generic-2 name I can't connect to this machine. VirtManager shows me generic-2 name and when I tried to opened it opens jk_efi. I do not renamed this machine only the deleted one.

I got this traceback:

Error launching details: Domain not found: no domain with matching uuid '51f4bf86-58f9-4ca9-ae25-f07068222415' (jk_efi)

Traceback (most recent call last):
  File "/usr/share/virt-manager/virtManager/engine.py", line 791, in _show_vm_helper
    details.show()
  File "/usr/share/virt-manager/virtManager/details.py", line 626, in show
    self.refresh_vm_state()
  File "/usr/share/virt-manager/virtManager/details.py", line 1356, in refresh_vm_state
    reason = self.vm.run_status_reason()
  File "/usr/share/virt-manager/virtManager/domain.py", line 1678, in run_status_reason
    return self.pretty_status_reason(self.status(), self.status_reason())
  File "/usr/share/virt-manager/virtManager/domain.py", line 446, in status_reason
    self._status_reason = self._backend.state()[1]
  File "/usr/lib64/python2.7/site-packages/libvirt.py", line 2573, in state
    if ret is None: raise libvirtError ('virDomainGetState() failed', dom=self)
libvirtError: Domain not found: no domain with matching uuid '51f4bf86-58f9-4ca9-ae25-f07068222415' (jk_efi)

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

How reproducible:
The second always.

Steps to Reproduce:
1. Create VM with "generic" name and as UEFI
2. Shutdown the machine
3. Rename the "generic" machine to "efi"
4. Delete the renamed VM "efi"
5. Create new VM in the same way as 1. (name "generic", UEFI)
6. Double click on this VM

Actual results:
Can't open "efi" VM. (Domain not found: no domain with matching uuid...)

Expected results:
Open new "generic" VM.

Additional info:
If this not related problem feel free to split them to two.
If you need some logs, please tell me what you need.
Comment 1 Cole Robinson 2015-11-04 14:34:55 EST
Thanks for the report. I fixed the second issue upstream:

commit d5e506869966ffa39bb400313ce9d001208dda38
Author: Cole Robinson <crobinso@redhat.com>
Date:   Tue Nov 3 15:56:39 2015 -0500

    engine: Update details window mapping when VM is renamed


The rename issue actually didn't reproduce with latest libvirt from virt-preview, but I hit some other issues when then trying to start the VM... I need to investigate more
Comment 2 Strahil Nikolov 2016-11-24 03:29:52 EST
I'm experiencing the same situation on Fedora 24.
Comment 3 Cole Robinson 2017-03-08 12:03:51 EST
Fixed upstream now:

commit 92c230d1113403b506e115416dff1218479b7116
Author: Pavel Hrdina <phrdina@redhat.com>
Date:   Mon Mar 6 09:43:10 2017 +0100

    domain: add support to rename domain with nvram vars file
Comment 4 Fedora Update System 2017-03-14 15:55:49 EDT
virt-manager-1.4.1-1.fc24 has been submitted as an update to Fedora 24. https://bodhi.fedoraproject.org/updates/FEDORA-2017-b3924e39e0
Comment 5 Fedora Update System 2017-03-15 15:56:16 EDT
virt-manager-1.4.1-1.fc24 has been pushed to the Fedora 24 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2017-b3924e39e0
Comment 6 Fedora Update System 2017-03-22 11:02:01 EDT
virt-manager-1.4.1-2.fc24 has been submitted as an update to Fedora 24. https://bodhi.fedoraproject.org/updates/FEDORA-2017-8a1c21cf03
Comment 7 Fedora Update System 2017-03-23 15:22:57 EDT
virt-manager-1.4.1-2.fc24 has been pushed to the Fedora 24 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2017-8a1c21cf03
Comment 8 Fedora Update System 2017-05-12 15:21:59 EDT
virt-manager-1.4.1-2.fc24 has been pushed to the Fedora 24 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.