Bug 1324447
Summary: | Report "pretty name" as a part of host OS data to distinguish between EL7 and NGN hosts | ||
---|---|---|---|
Product: | [oVirt] vdsm | Reporter: | Tareq Alayan <talayan> |
Component: | Core | Assignee: | Eli Mesika <emesika> |
Status: | CLOSED CURRENTRELEASE | QA Contact: | Lucie Leistnerova <lleistne> |
Severity: | medium | Docs Contact: | |
Priority: | high | ||
Version: | 4.18.0 | CC: | bugs, emesika, fdeutsch, huzhao, lleistne, lsvaty, mperina, oourfali |
Target Milestone: | ovirt-4.0.2 | Flags: | rule-engine:
ovirt-4.0.z+
rule-engine: planning_ack+ mperina: devel_ack+ lsvaty: testing_ack+ |
Target Release: | --- | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | infra | ||
Fixed In Version: | Doc Type: | Bug Fix | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2016-08-22 12:31:25 UTC | Type: | Bug |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | Infra | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: | |||
Bug Depends On: | |||
Bug Blocks: | 1346782 |
Description
Tareq Alayan
2016-04-06 10:54:54 UTC
Moving from 4.0 alpha to 4.0 beta since 4.0 alpha has been already released and bug is not ON_QA. Looking in the XMLRPC struct returned to the engine I see that we look for a "operatingSystem" field in that structure While debugging the code I go the following values for "operatingSystem": release" -> "2.1511.el7.centos.2.10 version" -> "7 name" -> "RHEL On he other hand , looking in the os_release file on the node I see the following : NAME="CentOS Linux" VERSION="7 (Core)" ID="centos" ID_LIKE="rhel fedora" VERSION_ID="7" VARIANT="oVirt Node 4.0.0_master" VARIANT_ID="ovirt-node" PRETTY_NAME="oVirt Node 4.0.0_master" ANSI_COLOR="0;31" CPE_NAME="cpe:/o:centos:centos:7" HOME_URL="https://www.ovirt.org/" BUG_REPORT_URL="https://bugzilla.redhat.com/" So, it seems that the problem origin is in VDSM oVirt 4.0 beta has been released, moving to RC milestone. oVirt 4.0 beta has been released, moving to RC milestone. The propper - and upstream aligned - handling is probably to include the id and variant_id fields of the os-release file. This tuple should allow to identify hosts reliably. *** Bug 1332466 has been marked as a duplicate of this bug. *** We decided to add pretty-name to current host OS identification (name, version, release) reported by VDSM ti distinguish between EL7 and NGN based on EL7. Moving back to POST as backport to ovirt-engine-4.0 branch is needed All patches are merged and there should be no risk around stability in those patches, so moving to 4.0.2 Setting target release to 4.18.8 as it's contained in latest VDSM build for ovirt-4.0.2-RC1 vdsm returns pretty name operatingSystem = {'name': 'RHEL', 'pretty_name': 'Red Hat Virtualization Host 4.0 (el7.2)', 'release': '1.el7', 'version': '4.0'} verified in vdsm-4.18.11-1.el7ev.x86_64 this is actually wrong, it should be release=$RHEL_RELEASE, version=$RHEL_VERSION Can you paste /etc/os-release, /etc/system-release, /etc/system-release-cpe and /etc/redhat-release of the host? Only pretty name should contain the RHV version/release Target release should be placed once a package build is known to fix a issue. Since this bug is not modified, the target version has been reset. Please use target milestone to plan a fix for a oVirt release. # cat /etc/os-release NAME="Red Hat Enterprise Linux" VERSION="7.2" VERSION_ID="7.2" ID="rhel" ID_LIKE="fedora" VARIANT="Red Hat Virtualization Host" VARIANT_ID="ovirt-node" PRETTY_NAME="Red Hat Virtualization Host 4.0 (el7.2)" ANSI_COLOR="0;31" CPE_NAME="cpe:/o:redhat:enterprise_linux:7.2:GA:hypervisor" HOME_URL="https://www.redhat.com/" BUG_REPORT_URL="https://bugzilla.redhat.com/" # FIXME REDHAT_BUGZILLA_PRODUCT="Red Hat Virtualization" REDHAT_BUGZILLA_PRODUCT_VERSION=7.2 REDHAT_SUPPORT_PRODUCT="Red Hat Virtualization" REDHAT_SUPPORT_PRODUCT_VERSION=7.2 # cat /etc/system-release Red Hat Enterprise Linux release 7.2 # cat /etc/system-release-cpe cpe:/o:redhat:enterprise_linux:7.2:ga:hypervisor # cat /etc/redhat-release Red Hat Enterprise Linux release 7.2 GUI: Hosts - General - Software OS Version: RHEL - 4.0 - 1.el7 OS Description: Red Hat Virtualization Host 4.0 (el7.2) Ok, it's wrong in the UI, but coirrect in the files. vdsm must be pulling it from the incorrect source. Eli, can you clarify where vdsm is pulling the version from? I currently can't see swhere it is getting the "4.0" version from. (In reply to Fabian Deutsch from comment #15) > Ok, it's wrong in the UI, but coirrect in the files. > vdsm must be pulling it from the incorrect source. > > Eli, can you clarify where vdsm is pulling the version from? I currently > can't see swhere it is getting the "4.0" version from. Fabian, VDSM uses the same code as for RHEL, so we are getting version and release from querying basename package. How do you identify the basename package? The assumption was that one of /etc/os-release, /etc/system-release, /etc/system-release-cpe and /etc/redhat-release was directly or indirectly used. Please take a look at https://gerrit.ovirt.org/gitweb?p=vdsm.git;a=blob;f=lib/vdsm/osinfo.py;h=3c6ab3bd99e0c7a127f551c38b4697bf79527fff;hb=refs/heads/master#l164 Okay, this explains it. So not the contents of this file is used, but rather the version/release of the owner of that file. Which is a different release file on Node. In the UI it is not to much of an issue. But I suppose tha this version/released is used for some decision, i.e. allowed update? I've opened bug 1368364 to track the incorrect reporting. Ths bug is actually verified, because pretty name is reported correctly. Discussed over BJ, clearing needinfo |