Bug 1249438

Summary: virt-what does not identify rhev/ovirt
Product: Red Hat Enterprise Linux 7 Reporter: Ryan Barry <rbarry>
Component: virt-whatAssignee: Richard W.M. Jones <rjones>
Status: CLOSED ERRATA QA Contact: Virtualization Bugs <virt-bugs>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 7.2CC: leiwang, linl, rbarry, rjones, sherold, wshi, xchen, ycui
Target Milestone: rc   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: virt-what-1.13-9.el7 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2017-08-01 20:35:30 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:
Bug Depends On:    
Bug Blocks: 1288337, 1301891    
Attachments:
Description Flags
0001-Add-oVirt-RHBZ-1249438.patch none

Description Ryan Barry 2015-08-03 01:47:58 UTC
Description of problem:
virt-what reports ovirt/rhev guests as "kvm" instead of 'ovirt' or 'rhev'

Version-Release number of selected component (if applicable):
virt-what-1.13-5.el7.x86_64

How reproducible:
100%

Steps to Reproduce:
1. Run virt-what in a rhev/ovirt guest
2.
3.

Actual results:
kvm

Expected results:
ovirt (or rhev, as 

Additional info:
This can be checked in dmidecode:
Manufacturer: oVirt
Product Name: oVirt Node

(it's also oVirt Node for the guests)

Comment 2 Richard W.M. Jones 2015-08-03 09:33:00 UTC
It should probably print several facts in this case, eg:

# virt-what
kvm
ovirt

Comment 3 Richard W.M. Jones 2015-08-03 11:25:22 UTC
Created attachment 1058754 [details]
0001-Add-oVirt-RHBZ-1249438.patch

Moving to 7.3 as the development period for 7.2 finished a couple
of weeks ago.

Please try the attached patch, or (perhaps better) give me ssh
access to a Linux VM running on RHEV-H.

Comment 4 Ryan Barry 2016-01-12 16:26:22 UTC
(In reply to Richard W.M. Jones from comment #3)
> Created attachment 1058754 [details]
> 0001-Add-oVirt-RHBZ-1249438.patch
> 
> Moving to 7.3 as the development period for 7.2 finished a couple
> of weeks ago.
> 
> Please try the attached patch, or (perhaps better) give me ssh
> access to a Linux VM running on RHEV-H.

This works, but outputs:

ovirt
kvm

It probably also needs:
skip_qemu_kvm=true

Comment 5 Richard W.M. Jones 2016-06-20 12:17:29 UTC
The patch mentioned in comment 3 is upstream:
http://git.annexia.org/?p=virt-what.git;a=commitdiff;h=1159ea3a8e4a65cf56804639498b692740723979

Comment 7 Xianghua Chen 2016-08-22 10:52:25 UTC
Failed with package:
virt-what-1.13-8.el7.x86_64

I have just installed an rhel7.2 guest image on RHEV.
# virt-what
kvm

Shouldn't it output:
kvm
rhev

I have looked into /usr/sbin/virt-what, it only checks for ovirt guest. I saw it is checked by dmidecode, but in rhev guest, the related info:
# dmidecode | grep 'Manufacturer:'
	Manufacturer: Red Hat
	Manufacturer: Red Hat
	Manufacturer: Red Hat
	Manufacturer: Red Hat


The rhel7.3 guest image on rhev for debug(for 1 day):
10.66.8.124
root/redhat

Comment 8 Richard W.M. Jones 2016-08-22 11:33:31 UTC
All Red Hat VMs have "Manufacturer: Red Hat".

A better bet looks like:

        Product Name: RHEV Hypervisor

I have added a commit upstream for this:

http://git.annexia.org/?p=virt-what.git;a=commit;h=73f639241174bde5066838ed67e959ef047da144

Comment 9 Richard W.M. Jones 2016-08-30 12:07:03 UTC
As RHEL 7.3 is in external beta now, I'm moving this to 7.4.

Comment 15 Xianghua Chen 2017-04-25 05:31:56 UTC
Verified with packages:
virt-what-1.13-10.el7.x86_64

Steps:
1. Prepare an ovirt env, install an rhel vm:
# virt-what
ovirt
kvm

2. Prepare a rhv env, install an rhel vm:
# virt-what
rhev
kvm

So verified.

Comment 16 errata-xmlrpc 2017-08-01 20:35:30 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:1952