Bug 1248360 - Loss guest's attribute of "hypervisorType" in esx/rhevm/hyperv mode
Loss guest's attribute of "hypervisorType" in esx/rhevm/hyperv mode
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: virt-who (Show other bugs)
7.2
x86_64 Linux
unspecified Severity medium
: rc
: ---
Assigned To: Radek Novacek
xingge
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2015-07-30 03:34 EDT by Liushihui
Modified: 2016-11-30 19:33 EST (History)
6 users (show)

See Also:
Fixed In Version: virt-who-0.14-4.el7
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2015-11-19 06:57:37 EST
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 Liushihui 2015-07-30 03:34:21 EDT
Description of problem:
When virt-who run at esx/rhevm/hyperv mode, virt-who can't report guest's "hypervisorType" in virt-who's log 

Version-Release number of selected component (if applicable):
virt-who-0.14-2.el7.noarch
subscription-manager-1.15.6-1.el7.x86_64
python-rhsm-1.15.3-1.el7.x86_64

How reproducible:
Always

Steps to Reproduce:
1.Register system to satellite
2.Configure virt-who run at esx mode
[root@hp-z220-05 ~]# cat /etc/virt-who.d/virt
[test-esx1]
type=esx
server=10.66.78.97
username=Administrator@vsphere.local
password=qwer1234P!
owner=ACME_Corporation
env=Library
3.Restart virt-who service and check virt-who log
[root@hp-z220-05 ~]# systemctl restart virt-who
[root@hp-z220-05 ~]# tail -f /var/log/rhsm/rhsm.log
2015-07-30 15:09:41,480 [INFO]  @subscriptionmanager.py:165 - Sending update in hosts-to-guests mapping: {
    "aee4ff00-8c33-11e2-994a-6c3be51d959a": [
        {
            "guestId": "42396a78-34aa-9fec-0f87-359998f98145", 
            "state": 5, 
            "attributes": {
                "active": 0, 
                "virtWhoType": "esx"
            }
        }
    ], 

Actual results:
Virt-who hasn't reported guest's "hypervisorType"

Expected results:
Virt-who also need to report guest's "hypervisorType" when run at esx/rhevm/hyperv


Additional info:
It hasn't this problem when virt-who run at libvirt mode.
Comment 1 Radek Novacek 2015-07-30 08:09:23 EDT
hypervisorType is currently used only in libvirt mode. It merely reports what is returned from this libvirt call:

http://libvirt.org/html/libvirt-libvirt-host.html#virConnectGetType

So it's "QEMU" in most cases.

What value should it have in other modes?
Comment 2 Radek Novacek 2015-08-04 04:10:57 EDT
There is 6 types of hypervisor_type property defined in OpenStack docs [0]: xen, qemu, lxc, uml, vmware, or hyperv. virt-who should use them too.

[0] http://docs.openstack.org/cli-reference/content/chapter_cli-glance-property.html
Comment 3 Radek Novacek 2015-08-18 11:56:38 EDT
Fixed in virt-who-0.14-4.el7.
Comment 5 Liushihui 2015-08-26 01:54:50 EDT
Verified it on virt-who-0.14-4.el7.noarch since virt-who can report guest's hypervisorType in vdsm,rhvm,esx and hyperv mode.Therefore, verify it.

Verified version
virt-who-0.14-4.el7.noarch
subscription-manager-1.15.9-6.el7.x86_64
python-rhsm-1.15.4-2.el7.x86_64
Satellite6.1.0-20150820.0

Verified process:
1.Register system to satellite
2.Configure virt-who run at esx mode
3.Restart virt-who service and check virt-who log, it show guest's hypervisorType is "vmware"
        {
            "guestId": "564d1d17-06d9-46c3-beea-fed130d564e7", 
            "state": 5, 
            "attributes": {
                "active": 0, 
                "virtWhoType": "esx", 
                "hypervisorType": "vmware" =================It has been added
            }
        }
4. Configure virt-who run at hyperv mode,Restart virt-who service and check virt-who log, it show guest's hypervisorType is "hyperv" 
        {
            "guestId": "CFC6D39C-A9B5-9F44-AB2F-BCF5C6F8EC8F", 
            "state": 1, 
            "attributes": {
                "active": 1, 
                "virtWhoType": "hyperv", 
                "hypervisorType": "hyperv"=================It has been added
            }
        }
5. Configure virt-who run at vdsm mode,Restart virt-who service and check virt-who log, it show guest's hypervisorType is "qemu"
    {
        "guestId": "4f1f93b8-c4c5-424d-89d8-1822367d2274", 
        "state": 1, 
        "attributes": {
            "active": 1, 
            "virtWhoType": "vdsm", 
            "hypervisorType": "qemu"=================It has been added
        }
    }
 6. Configure virt-who run at rhevm mode, Restart virt-who service and check virt-who log, it show guest's hypervisorType is "qemu"
    "88d979a3-34f8-4cca-84e8-df0988257ba6": [
        {
            "guestId": "4f1f93b8-c4c5-424d-89d8-1822367d2274", 
            "state": 1, 
            "attributes": {
                "active": 1, 
                "virtWhoType": "rhevm", 
                "hypervisorType": "qemu"=================It has been added
            }
        }
    ]

Result: virt-who can report guest's hypervisorType in vdsm,rhvm,esx and hyperv mode separately.
Comment 6 errata-xmlrpc 2015-11-19 06:57:37 EST
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://rhn.redhat.com/errata/RHBA-2015-2370.html

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