Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
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 1712458

Summary: [machines] The function of 'Auto-detect guest operating system' is not available on rhel 7.7
Product: Red Hat Enterprise Linux 7 Reporter: YunmingYang <yunyang>
Component: libosinfoAssignee: Fabiano FidĂȘncio <fidencio>
Status: CLOSED ERRATA QA Contact: Desktop QE <desktop-qa-list>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 7.7CC: cfergeau, kkoukiou, leiwang, mpitt, qiyuan, tpelka, vbudikov, wshi
Target Milestone: rcFlags: vbudikov: needinfo+
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: libosinfo-1.1.0-3.el7 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2019-08-06 12:38:49 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:

Description YunmingYang 2019-05-21 14:39:07 UTC
Description of problem:
Create a VM with using the installation source type which is 'URL' and input an URL for the installation source (like 'https://mirrors.tuna.tsinghua.edu.cn/centos/7/os/x86_64/').Then, the 'OS Vendor' and the 'Operating System' don't change to expect value

Version-Release number of selected component (if applicable):
osinfo-db-tools-1.1.0-1.el7.x86_64
osinfo-db-20190319-2.el7.noarch
libosinfo-1.1.0-2.el7.x86_64
cockpit-191-1.el7.x86_64
cockpit-bridge-191-1.el7.x86_64
cockpit-ws-191-1.el7.x86_64
cockpit-machines-193-1.el7.x86_64
cockpit-system-191-1.el7.noarch
libvirt-dbus-1.3.0-1.el7.x86_64

How reproducible:
100%

Steps to Reproduce:
1. Create a VM with using the installation source type which is 'URL' and input an url for the installation source (like 'https://mirrors.tuna.tsinghua.edu.cn/centos/7/os/x86_64/').

Actual results:
The 'OS Vendor' and the 'Operating System' don't change to expect values

Expected results:
The 'OS Vendor' and the 'Operating System' should change to expect values

Additional info:
This function is available on the fedora-30, and the version of libosinfo is 1.4.0-3

Comment 2 Katerina Koukiou 2019-05-22 09:47:59 UTC
It's libosinfo issue, it can't detect trees. Moving to the appropriate component.

Simplified reproducer for the issue taking out the cockpit-machines factor: 

[admin@localhost ~]$ osinfo-detect -t tree 'https://mirrors.tuna.tsinghua.edu.cn/centos/7/os/x86_64/'
Error parsing installer tree: Failed to load .treeinfo file: Operation not supported

Or with the python script that we are using for autodetection:

 # python2 autoDetectOS.py https://download.fedoraproject.org/pub/fedora/linux/releases/29/Server/x86_64/os
Traceback (most recent call last):
  File "autoDetectOS.py", line 21, in <module>
    tree = Libosinfo.Tree().create_from_location(sys.argv[1])
GLib.Error: g-io-error-quark: Failed to load .treeinfo file: Operation not supported (15)


The python script is located here: https://github.com/cockpit-project/cockpit/blob/master/pkg/machines/components/create-vm-dialog/autoDetectOS.py

Comment 3 Fabiano FidĂȘncio 2019-05-22 11:31:32 UTC
In order to fix this issue we'll need to backport:
 4fe69c9fe31befe3caa55bbaac0bcfa5e605f028
 fc431d26ca4d61213e72fa373354828909550033
 d56e33b47c806522378f267b50c354e48df25f98
 705b08bb3fa44a2266abdd5d145544c67ef0d882
 6eab80bac760dc44dbefe403ef67a3a80dca2392
 1c4deff7dc94da6157f64c398a58375a2c97e35b
 e8e0ca9024847aca9d079ffb34a2bbd0494fe978
 d7bc838a96acf5f058e13d2b49157b4ba396cd87
 be4906d64b091397b897d351fd09c1146bc10f93
 ff471e84587597029ab0f1f67b1dc11f5578a0ee

Being the first and the last commits desirable but not mandatory.

Comment 14 errata-xmlrpc 2019-08-06 12:38:49 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/RHEA-2019:2045