Bugzilla (bugzilla.redhat.com) will be under maintenance for infrastructure upgrades and will not be available on July 31st between 12:30 AM - 05:30 AM UTC. We appreciate your understanding and patience. You can follow status.redhat.com for details.
Bug 1573172 - Failed to get mapping info - virt-who - KeyError: 'config.network.dnsConfig.hostName' [rhel-7.5.z]
Summary: Failed to get mapping info - virt-who - KeyError: 'config.network.dnsConfig.h...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: virt-who
Version: 7.5
Hardware: All
OS: All
high
high
Target Milestone: rc
: ---
Assignee: candlepin-bugs
QA Contact: Eko
URL:
Whiteboard:
Depends On: 1569299
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-04-30 11:57 UTC by Oneata Mircea Teodor
Modified: 2021-06-10 16:01 UTC (History)
14 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of: 1569299
Environment:
Last Closed: 2018-05-14 16:13:46 UTC
Target Upstream Version:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github candlepin virt-who pull 138 0 None closed 1569299: try/exception needed for hypervisor_id check 2020-11-16 22:43:11 UTC
Red Hat Knowledge Base (Solution) 3426901 0 None None None 2018-04-30 11:57:55 UTC
Red Hat Product Errata RHBA-2018:1409 0 None None None 2018-05-14 16:13:49 UTC

Description Oneata Mircea Teodor 2018-04-30 11:57:45 UTC
This bug has been copied from bug #1569299 and has been proposed to be backported to 7.5 z-stream (EUS).

Comment 3 Shuai Yan 2018-05-03 06:37:17 UTC
rhel: 7.5 (Maipo)
satellite: build: 6.3.1

Before upgrading:
    virt-who: virt-who-0.21.5-1.el7.noarch
using a changed key like: 'xxx_config.network.dnsConfig.hostName'
got log:
2018-05-03 02:20:37,617 [virtwho.main DEBUG] MainProcess(30787):Thread-2 @esx.py:_prepare:132 - Creating ESX event filter
2018-05-03 02:20:38,420 [virtwho.main ERROR] MainProcess(30787):Thread-2 @virt.py:run:388 - Thread 'esx' fails with exception:
Traceback (most recent call last):
  File "/usr/lib/python2.7/site-packages/virtwho/virt/virt.py", line 379, in run
    self._run()
  File "/usr/lib/python2.7/site-packages/virtwho/virt/esx/esx.py", line 215, in _run
    assoc = self.getHostGuestMapping()
  File "/usr/lib/python2.7/site-packages/virtwho/virt/esx/esx.py", line 262, in getHostGuestMapping
    uuid = host['xxx_config.network.dnsConfig.hostName']
KeyError: 'xxx_config.network.dnsConfig.hostName'


Upgrading virt-who:
[root@sgi-uv2-01 ~]# rpm -Uvh ./virt-who-0.21.7-1.el7_5.noarch.rpm 
Preparing...                          ################################# [100%]
Updating / installing...
   1:virt-who-0.21.7-1.el7_5          ################################# [ 50%]
Cleaning up / removing...
   2:virt-who-0.21.5-1.el7            ################################# [100%]



After upgrading:
    virt-who: virt-who-0.21.7-1.el7_5.noarch
using a change key like 'xxx_config.network.dnsConfig.hostName'
got log:
2018-05-03 02:28:29,965 [virtwho.main DEBUG] MainProcess(30826):Thread-2 @esx.py:_prepare:129 - Log into ESX
2018-05-03 02:28:31,793 [virtwho.main DEBUG] MainProcess(30826):Thread-2 @esx.py:_prepare:132 - Creating ESX event filter
2018-05-03 02:28:32,549 [virtwho.main DEBUG] MainProcess(30826):Thread-2 @esx.py:getHostGuestMapping:268 - Host 'host-179' doesn't have hypervisor_id property
2018-05-03 02:28:32,549 [virtwho.main DEBUG] MainProcess(30826):Thread-2 @esx.py:getHostGuestMapping:268 - Host 'host-173' doesn't have hypervisor_id property
2018-05-03 02:28:32,549 [virtwho.main INFO] MainProcess(30826):Thread-2 @virt.py:_send_data:922 - Report for config "esx" gathered, placing in datastore


After upgrading virt-who, and run virt-who again, we cannot get the error log as before. 
So mark this as VERIFIED.

Comment 6 errata-xmlrpc 2018-05-14 16:13:46 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-2018:1409


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