Red Hat Satellite engineering is moving the tracking of its product development work on Satellite 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 "Satellite project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs will be migrated starting at the end of May. 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 "Satellite project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/SAT-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 2087753 - Simplify self-upgrade mechanism
Summary: Simplify self-upgrade mechanism
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: Satellite Maintain
Version: 6.11.0
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: 6.11.1
Assignee: Amit Upadhye
QA Contact: Gaurav Talreja
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2022-05-18 12:49 UTC by Amit Upadhye
Modified: 2022-11-28 10:15 UTC (History)
3 users (show)

Fixed In Version: rubygem-foreman_maintain-1.0.13,tfm-rubygem-foreman_maintain-1.0.13-1
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 2093403 2106093 (view as bug list)
Environment:
Last Closed: 2022-07-27 17:27:09 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Foreman Issue Tracker 34937 0 Normal Closed Simplify self-upgrade mechanism 2022-05-22 06:40:45 UTC
Red Hat Issue Tracker SAT-14060 0 None None None 2022-11-28 10:15:12 UTC
Red Hat Product Errata RHBA-2022:5742 0 None None None 2022-07-27 17:27:19 UTC

Description Amit Upadhye 2022-05-18 12:49:49 UTC
The self-upgrade mechanism deals with system repositories. This slows downs the overall self-upgrade command as it involves 'yum-config-manager' and 'subscription-manager' to enable and disable repositories. Instead of this the yum options are better choice which does not need to enable/disable system repositories and get the job done of updating packages.

Comment 1 Amit Upadhye 2022-05-18 12:49:54 UTC
Created from redmine issue https://projects.theforeman.org/issues/34937

Comment 2 Amit Upadhye 2022-05-18 12:49:56 UTC
Upstream bug assigned to aupadhye

Comment 3 Bryan Kearney 2022-05-19 16:04:56 UTC
Moving this bug to POST for triage into Satellite since the upstream issue https://projects.theforeman.org/issues/34937 has been resolved.

Comment 6 Gaurav Talreja 2022-07-18 14:14:12 UTC
Verified.

Tested on Satellite 6.11.1 Snap 2.0
Version: rubygem-foreman_maintain-1.0.14-1.el8sat.noarch

1. # foreman-maintain self-upgrade
2. Add repo for next major version maintenance repo under /etc/yum.repos.d/ for disconnected/testing environment.
3. # foreman-maintain self-upgrade --maintenance-repo-label sat-maintain 
OR
3. # MAINTENANCE_REPO_LABEL='sat-maintain' foreman-maintain self-upgrade

Observation:
By not dealing with system repos, like saving enabled repos into yaml, and enabling/disabling system repos, the new self-upgrade mechanism makes it easier to update satellite-maintain/rubygem-foreman_maintain packages with yum options.

When using rhsm repos in connected environment it uses yum options, for RHEL7 "--enablerepo=rhel-7-server-rpms --enablerepo=rhel-server-rhscl-7-rpms --enablerepo=rhel-7-server-satellite-maintenance-6.12-rpms", whereas for RHEL8 "--enablerepo=rhel-8-for-x86_64-baseos-rpms --enablerepo=rhel-8-for-x86_64-appstream-rpms --enablerepo=satellite-maintenance-6.12-for-rhel-8-x86_64-rpms"

And for disconnected/testing environment it just uses yum options, for RHEL7 "--enablerepo=sat-maintain", whereas for RHEL8 "--enablerepo=rhel-8-for-x86_64-baseos-rpms --enablerepo=rhel-8-for-x86_64-appstream-rpms --enablerepo=sat-maintain_el8", where this RH repos shouldn't be enabled for el8, discussed this with Amit and created a separate BZ 2108169 to track

Comment 11 errata-xmlrpc 2022-07-27 17:27:09 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.1 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-2022:5742


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