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 1449509 - virt-manager prints error for network interface without an IP address
Summary: virt-manager prints error for network interface without an IP address
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: virt-manager
Version: 7.4
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: rc
: ---
Assignee: Pavel Hrdina
QA Contact: Virtualization Bugs
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2017-05-10 07:56 UTC by Pavel Hrdina
Modified: 2017-08-01 21:04 UTC (History)
4 users (show)

Fixed In Version: virt-manager-1.4.1-4.el7
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2017-08-01 21:04:33 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
screenshot for verification (62.22 KB, image/png)
2017-05-17 07:57 UTC, zhoujunqin
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2017:2072 0 normal SHIPPED_LIVE virt-manager bug fix and enhancement update 2017-08-01 18:36:34 UTC

Description Pavel Hrdina 2017-05-10 07:56:00 UTC
Description of problem:
If there is an interface without an IP address virt-manager prints error in the "Network Interface" configuration window.

Version-Release number of selected component (if applicable):
virt-manager-1.4.1-2.el7

How reproducible:
100%

Steps to Reproduce:
1. Create and activate new VLAN interface, make sure that there is no IPv4 address
2. Double-click on connection and navigate to "Network Interface" page.
3. Click on the created VLAN interface

Actual results:
Error selecting interface: 'NoneType' object has not attribute 'ips'

Expected results:
There are information about the selected interface

Additional info:
[Wed, 10 May 2017 09:53:37 virt-manager 5090] ERROR (host:816) 'NoneType' object has no attribute 'ips'
Traceback (most recent call last):
  File "/usr/share/virt-manager/virtManager/host.py", line 814, in interface_selected
    self.populate_interface_state(connkey)
  File "/usr/share/virt-manager/virtManager/host.py", line 831, in populate_interface_state
    ipv4 = interface.get_ipv4()
  File "/usr/share/virt-manager/virtManager/interface.py", line 151, in get_ipv4
    proto, ips = self._get_ip("ipv4")
  File "/usr/share/virt-manager/virtManager/interface.py", line 141, in _get_ip
    for ip in activeProto.ips:
AttributeError: 'NoneType' object has no attribute 'ips'

Comment 2 Pavel Hrdina 2017-05-10 10:42:39 UTC
Upstream commit:

commit 86e2c23d71a1bdaa153a578e98bf91d47a045f36
Author: Pavel Hrdina <phrdina>
Date:   Wed May 10 10:00:39 2017 +0200

    interface: don't print error for active interface without an IP address

Comment 5 zhoujunqin 2017-05-17 07:56:39 UTC
I can reproduce this issue with package:
virt-manager-1.4.1-3.el7.noarch

Steps:
Environment:
# service NetworkManager start

1. Create a new bridge 'br' based on eno1.
Launch virt-manager -> double-click on connection -> navigate to "Network Interface" page -> click 'Add interface' button -> Select 'Bridge', then click 'Forward'
Name: br1
Start mode: none
Active now: Tick on
IP settings: IPv4: DHCP
Bridge setting: STP off, delay 0.00 sec
Choose interface(s) to bridge: eno1
Then click 'Finish'.

2. Click on the interface 'br1'.

Resut:
After step3, there is a error:
Error selecting interface: 'NoneType' object has not attribute 'ips'

Also checked virt-manager debug info:
[Wed, 17 May 2017 03:51:12 virt-manager 5399] ERROR (host:816) 'NoneType' object has no attribute 'ips'
Traceback (most recent call last):
  File "/usr/share/virt-manager/virtManager/host.py", line 814, in interface_selected
    self.populate_interface_state(connkey)
  File "/usr/share/virt-manager/virtManager/host.py", line 831, in populate_interface_state
    ipv4 = interface.get_ipv4()
  File "/usr/share/virt-manager/virtManager/interface.py", line 151, in get_ipv4
    proto, ips = self._get_ip("ipv4")
  File "/usr/share/virt-manager/virtManager/interface.py", line 141, in _get_ip
    for ip in activeProto.ips:
AttributeError: 'NoneType' object has no attribute 'ips'


Then try to verify this bug with new build:
virt-manager-1.4.1-4.el7.noarch
libvirt-3.2.0-5.virtcov.el7.x86_64
qemu-kvm-rhev-2.9.0-5.el7.x86_64

Steps as above, virt-manager can show running interface without an IP address normally as Screenshot. 

So move this bug from ON_QA to VERIFIED.

Comment 6 zhoujunqin 2017-05-17 07:57:53 UTC
Created attachment 1279562 [details]
screenshot for verification

Comment 7 errata-xmlrpc 2017-08-01 21:04:33 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-2017:2072


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