Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
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 1667308

Summary: Cannot modify guest's name on uefi firmware when creating new vm on rhel 7
Product: Red Hat Enterprise Linux 7 Reporter: zonglin jiang <zjiang>
Component: virt-managerAssignee: Pavel Hrdina <phrdina>
Status: CLOSED ERRATA QA Contact: Virtualization Bugs <virt-bugs>
Severity: medium Docs Contact:
Priority: medium    
Version: 7.6CC: juzhou, mxie, mzhan, tzheng, xiaodwan, zili
Target Milestone: rc   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: virt-manager-1.5.0-2.el7 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: 1667025 Environment:
Last Closed: 2019-08-06 13:08:01 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 zonglin jiang 2019-01-18 06:25:41 UTC
Version-Release number of selected component (if applicable):

virt-manager-1.5.0-1.el7.noarch
package qemu-kvm is not installed
libvirt-4.5.0-10.el7_6.3.x86_64
libvirt-python-4.5.0-1.el7.x86_64
kernel-3.10.0-957.el7.x86_64

How reproducible
100%

Steps to Reproduce
1.Launch virt-manager, create a new vm
2.In the last step, check customize configuration before install 
3.Click overview, for "firmware" choose "uefi", click apply
4.Modify name to a legal one, click apply

Actual results:
After step 4,Error pops up
Error apply changes: 'NoneType' object has no attribute 'rfind'

Expected results:
No errors pop up and the name can be modified successfully.

Additionally info:
Thishappens on both rhel7 and rhel8
virt-manager --debug shows:

[Fri, 18 Jan 2019 14:24:03 virt-manager 8264] DEBUG (error:99) error dialog message:
summary=Error apply changes: 'NoneType' object has no attribute 'rfind'
details=Error apply changes: 'NoneType' object has no attribute 'rfind'

Traceback (most recent call last):
  File "/usr/share/virt-manager/virtManager/details.py", line 1887, in config_apply
    ret = self.config_overview_apply()
  File "/usr/share/virt-manager/virtManager/details.py", line 1979, in config_overview_apply
    self.vm.rename_domain(self.widget("overview-name").get_text())
  File "/usr/share/virt-manager/virtManager/domain.py", line 596, in rename_domain
    new_nvram, old_nvram = self._copy_nvram_file(new_name)
  File "/usr/share/virt-manager/virtManager/domain.py", line 571, in _copy_nvram_file
    nvram_dir = os.path.dirname(old_nvram.path)
  File "/usr/lib64/python2.7/posixpath.py", line 129, in dirname
    i = p.rfind('/') + 1
AttributeError: 'NoneType' object has no attribute 'rfind'

Comment 2 Pavel Hrdina 2019-03-05 14:55:53 UTC
Upstream commit:

commit b206931eb9644e33b31c3141ba3403993898a090
Author: Pavel Hrdina <phrdina>
Date:   Tue Mar 5 15:49:23 2019 +0100

    virtManager: domain: override rename_domain in vmmDomainVirtinst

Comment 5 ysu@redhat.com 2019-04-29 08:48:28 UTC
I can reproduce this issue with package:
virt-manager-1.5.0-1.el7.noarch

Then try to verify this bug with new build:
virt-manager-1.5.0-3.el7.noarch
virt-install-1.5.0-3.el7.noarch
libvirt-4.5.0-12.el7.x86_64
qemu-kvm-rhev-2.12.0-26.el7.x86_64
libvirt-python-4.5.0-1.el7.x86_64

Steps:
1.Check the modification of guest's name on uefi firmware.
1.1 Launch virt-manager, create a new vm
1.2 In the last step, check customize configuration before install 
1.3 Click overview, for "firmware" choose "uefi", click apply
1.4 Modify name to rhel7.6-uefi,then click apply

Result:After modify guest's name to a legal one,the installation is success without error pops up.

I move this bug from ON_QA to VERIFIED based on above testing.

Comment 7 errata-xmlrpc 2019-08-06 13:08:01 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.

https://access.redhat.com/errata/RHBA-2019:2232