Bugzilla will be upgraded to version 5.0. The upgrade date is tentatively scheduled for 2 December 2018, pending final testing and feedback.
Bug 1573172 - Failed to get mapping info - virt-who - KeyError: 'config.network.dnsConfig.hostName' [rhel-7.5.z]
Failed to get mapping info - virt-who - KeyError: 'config.network.dnsConfig.h...
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: virt-who (Show other bugs)
7.5
All All
high Severity high
: rc
: ---
Assigned To: candlepin-bugs
Eko
: Triaged, ZStream
Depends On: 1569299
Blocks:
  Show dependency treegraph
 
Reported: 2018-04-30 07:57 EDT by Oneata Mircea Teodor
Modified: 2018-05-17 10:55 EDT (History)
12 users (show)

See Also:
Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: 1569299
Environment:
Last Closed: 2018-05-14 12:13:46 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Knowledge Base (Solution) 3426901 None None None 2018-04-30 07:57 EDT
Github candlepin/virt-who/pull/138 None None None 2018-04-30 07:57 EDT
Red Hat Product Errata RHBA-2018:1409 None None None 2018-05-14 12:13 EDT

  None (edit)
Description Oneata Mircea Teodor 2018-04-30 07:57:45 EDT
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 02:37:17 EDT
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 12:13:46 EDT
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.