Bug 2190195

Summary: unable to install satellite 6.12 on rhel8.8 - ansible-core version is too new
Product: Red Hat Satellite Reporter: Odilon Sousa <osousa>
Component: PackagingAssignee: satellite6-bugs <satellite6-bugs>
Status: CLOSED ERRATA QA Contact: Lukas Pramuk <lpramuk>
Severity: unspecified Docs Contact:
Priority: high    
Version: 6.11.4CC: bbuckingham, egolov, ehelms, lpramuk, mhulan, ogajduse, pcreech, smallamp
Target Milestone: 6.11.5Keywords: AutomationBlocker, TestBlockerForLayeredProduct, Triaged
Target Release: Unused   
Hardware: Unspecified   
OS: Linux   
Whiteboard:
Fixed In Version: ansible-collection-redhat-satellite-3.6.0-4,tfm-rubygem-smart_proxy_ansible-3.3.1-5 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: 2166460 Environment:
Last Closed: 2023-05-10 19:31:19 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Comment 2 Lukas Pramuk 2023-05-02 09:31:19 UTC
FailedQA.

@Satellite 6.11.5.3

the following rpms have wrong requires:

1) ansible-collection-redhat-satellite-3.6.0-3.el8sat.noarch
(ansible >= 2.9 or ansible-core)
(python38-pyyaml if ansible-core < 2.13)
(python38-requests if ansible-core < 2.13)
(python39-pyyaml if ansible-core >= 2.13)
(python39-requests if ansible-core >= 2.13)

>>> ansible-collection-redhat-satellite should require python3.11-xxx rpms on RHEL8.8
>>> (python3.11-pyyaml if ansible-core >= 2.14.2-3)
>>> (python3.11-requests if ansible-core >= 2.14.2-3)

2) rubygem-smart_proxy_ansible-3.3.1-4.el8sat.noarch
(ansible or ansible-core)
(python38-psutil if ansible-core < 2.13)
(python39-psutil if ansible-core >= 2.13)

>>> if there is now runner 2.0+ on EL8 there is no need for psutil hack 
>>> yet I miss "ansible-runner >= 2" rpm requirement we have on 6.12 and 6.13 (are we leaving this only on installer that pulls ansible-rpm in ?)

Comment 3 Patrick Creech 2023-05-02 14:05:48 UTC
Is this causing a failure on installation?  Or is this an rpm correctness issue?

Comment 4 Lukas Pramuk 2023-05-02 14:19:11 UTC
I don't insist on 2) but 1) is important

If we have for some reason python*-pyyaml and python*-requests requires I expect python3.11 requires variants too.

(python3.11-pyyaml if ansible-core >= 2.14.2-3)
(python3.11-requests if ansible-core >= 2.14.2-3)

Comment 5 Evgeni Golov 2023-05-03 07:47:12 UTC
https://gitlab.cee.redhat.com/satellite/satellite-packaging/-/merge_requests/7097 should fix both findings

Comment 8 Lukas Pramuk 2023-05-06 08:50:07 UTC
VERIFIED.

@Satellite 6.11.5.3 Snap2.1
ansible-collection-redhat-satellite-3.6.0-4.el8sat.noarch
rubygem-smart_proxy_ansible-3.3.1-5.el8sat.noarch
ansible-runner-2.2.1-3.el8sat.noarch

A) by this simple reproducer:

# rpm -qR ansible-collection-redhat-satellite | grep core
(ansible >= 2.9 or ansible-core)
(python3.11-pyyaml if ansible-core >= 2.14.2-3)
(python3.11-requests if ansible-core >= 2.14.2-3)
(python38-pyyaml if ansible-core < 2.13)
(python38-requests if ansible-core < 2.13)
(python39-pyyaml if (ansible-core >= 2.13 and ansible-core < 2.14.2-3))
(python39-requests if (ansible-core >= 2.13 and ansible-core < 2.14.2-3))

# rpm -qR rubygem-smart_proxy_ansible | grep runner
ansible-runner >= 2

>>> requirements are RHEL8.8 ready


B) by running Satellite in-place upgrade of RHEL to RHEL-8.8 (using internal RHEL candidate repo)

# yum repolist
...
repo id                                                                   repo name
AppStream                                                                 AppStream
BaseOS                                                                    BaseOS
Sat6-CI_Red_Hat_Satellite_6_11_Composes_Satellite_6_11_RHEL8              Satellite 6.11 RHEL8
Sat6-CI_Satellite_6_11_Composes_Satellite_Maintenance_6_11_RHEL8          Satellite Maintenance 6.11 RHEL8

# satellite-maintain upgrade run --target-version 6.11.z -w repositories-setup,repositories-validate -y 
...
Update package(s) :                                                   [OK]
--------------------------------------------------------------------------------
Procedures::Installer::Upgrade:                                       [OK]
--------------------------------------------------------------------------------
Execute upgrade:run rake task:                                        [OK]
--------------------------------------------------------------------------------
...
--------------------------------------------------------------------------------
Upgrade finished.

>>> there are now no dependency issues on RHEL-8.8 as inplace upgrade to RHEL-8.8 is successful

C) by running Ansible REX at Satellite on RHEL8.8

# jobid=$(hammer --csv host ansible-roles play --name $(hostname) | awk -F, 'NR>1{print$2}')

# hammer job-invocation output --id $jobid --host $(hostname)
[DEPRECATION WARNING]: [defaults]callback_whitelist option, normalizing names 
to new standard, use callbacks_enabled instead. This feature will be removed 
from ansible-core in version 2.15. Deprecation warnings can be disabled by 
setting deprecation_warnings=False in ansible.cfg.
...

PLAY RECAP *********************************************************************
satellite.example.com : ok=6    changed=1    unreachable=0    failed=0    skipped=8    rescued=0    ignored=0
Exit status: 0

>>> REX action and namely 'redhat.satellite.foreman' callback finished successfully

Comment 12 errata-xmlrpc 2023-05-10 19:31:19 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 (Satellite 6.11.5.3 Async Bug Fix Update), 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-2023:2729