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 1862419

Summary: The 'repo-override' command is not supported by the server.
Product: Red Hat Enterprise Linux 8 Reporter: John Sefler <jsefler>
Component: subscription-managerAssignee: Jiri Hnidek <jhnidek>
Status: CLOSED ERRATA QA Contact: Red Hat subscription-manager QE Team <rhsm-qe>
Severity: high Docs Contact:
Priority: urgent    
Version: 8.3CC: arpandey, cdonnell, jhnidek, redakkan, wpoteat
Target Milestone: rcKeywords: Regression, Triaged
Target Release: ---Flags: pm-rhel: mirror+
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-11-04 01:39:41 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 John Sefler 2020-07-31 11:59:41 UTC
Description of problem:

I am blocked from using the subscription-manager repo-override module.   This may be a IT-Candlepin issue.


Version-Release number of selected component (if applicable):
[root@hpe-dl380pgen8-02-vm-11 ~]# rpm -q subscription-manager
subscription-manager-1.27.11-1.el8.x86_64


How reproducible:


Steps to Reproduce:
[root@hpe-dl380pgen8-02-vm-11 ~]# subscription-manager register --auto-attach --serverurl=subscription.rhsm.stage.redhat.com
Registering to: subscription.rhsm.stage.redhat.com:443/subscription
Username: stage_auto_testuser
Password: 
CACHED_SYSPURPOSE: /var/lib/rhsm/cache/syspurpose.json
The system has been registered with ID: b200fd11-3f63-4ddc-9f33-5db03917e816
The registered system name is: hpe-dl380pgen8-02-vm-11.hpe2.lab.eng.bos.redhat.com
Installed Product Current Status:
Product Name: Red Hat Enterprise Linux for x86_64 Beta
Status:       Subscribed

[root@hpe-dl380pgen8-02-vm-11 ~]# subscription-manager repo-override --list
Error: The 'repo-override' command is not supported by the server.
[root@hpe-dl380pgen8-02-vm-11 ~]# 


Actual results:
  Error: The 'repo-override' command is not supported by the server.

Expected results:
  A friendly list (possible empty) of all my repo overrides



Additional info:
[root@hpe-dl380pgen8-02-vm-11 ~]# tail -10 /var/log/rhsm/rhsm.log 
2020-07-31 07:56:09,639 [DEBUG] subscription-manager:453314:MainThread @connection.py:169 - Environment variable NO_PROXY= will be used
2020-07-31 07:56:09,639 [DEBUG] subscription-manager:453314:MainThread @connection.py:265 - Connection built: host=subscription.rhsm.stage.redhat.com port=443 handler=/subscription auth=identity_cert ca_dir=/etc/rhsm/ca/ insecure=False
2020-07-31 07:56:09,640 [DEBUG] subscription-manager:453314:MainThread @connection.py:169 - Environment variable NO_PROXY= will be used
2020-07-31 07:56:09,640 [DEBUG] subscription-manager:453314:MainThread @connection.py:265 - Connection built: host=subscription.rhsm.stage.redhat.com port=443 handler=/subscription auth=none
2020-07-31 07:56:09,640 [DEBUG] subscription-manager:453314:MainThread @managercli.py:367 - Consumer Identity name=hpe-dl380pgen8-02-vm-11.hpe2.lab.eng.bos.redhat.com uuid=b200fd11-3f63-4ddc-9f33-5db03917e816
2020-07-31 07:56:09,641 [DEBUG] subscription-manager:453314:MainThread @connection.py:685 - Making request: GET /subscription/
2020-07-31 07:56:09,642 [DEBUG] subscription-manager:453314:MainThread @connection.py:570 - Loaded CA certificates from /etc/rhsm/ca/: redhat-entitlement-authority.pem, redhat-uep.pem
2020-07-31 07:56:10,184 [DEBUG] subscription-manager:453314:MainThread @connection.py:779 - Response time: 0.4651527404785156, Smoothed response time: 0.4651527404785156
2020-07-31 07:56:10,185 [DEBUG] subscription-manager:453314:MainThread @connection.py:756 - Response: status=200, requestUuid=75cdc0e9-5675-469c-9b59-25c734203377, request="GET /subscription/"
2020-07-31 07:56:10,186 [DEBUG] subscription-manager:453314:MainThread @connection.py:954 - Server supports the following resources: {'distributor_versions': '/distributor_versions', 'status': '/status', 'deleted_consumers': '/deleted_consumers', 'users': '/users', 'pools': '/pools', 'activation_keys': '/activation_keys', 'cdn': '/cdn', 'content_overrides': '/consumers/{consumer_uuid}/content_overrides', 'consumers': '/consumers', 'consumertypes': '/consumertypes', 'crl': '/crl', '': '/', 'content': '/content', 'subscriptions': '/subscriptions', 'products': '/products', 'roles': '/roles', 'serials': '/serials', 'admin': '/admin', 'owners': '/owners', 'hypervisors': '/hypervisors', 'guestids': '/consumers/{consumer_uuid}/guestids', 'entitlements': '/entitlements', 'jobs': '/jobs', 'rules': '/rules', 'packages': '/consumers/{consumer_uuid}/packages'}
[root@hpe-dl380pgen8-02-vm-11 ~]#

Comment 5 Archana Pandey 2020-08-10 10:03:38 UTC
Verifying against latest subscription-manager build 1.27.13-1.el8.x86_64

Version-Release number of selected component (if applicable):
[root@ibm-x3650m4-01-vm-14 ~]# subscription-manager  version
server type: Red Hat Subscription Management
subscription management server: 3.1.16-1
subscription management rules: 5.40
subscription-manager: 1.27.13-1.el8

Steps to verify:
[root@ibm-x3650m4-01-vm-14 ~]# rpm -qa subscription-manager --changelog | grep 1862419
- 1862419: Make repo-override working again (jhnidek)

verifying with production server

[root@ibm-x3650m4-01-vm-14 ~]# subscription-manager register --auto-attach --serverurl=subscription.rhsm.redhat.com
Registering to: subscription.rhsm.redhat.com:443/subscription
Username: *****
Password: 
The system has been registered with ID: d4ba1674-8e51-4fa2-ae62-814e1ba3a743
The registered system name is: ibm-x3650m4-01-vm-14.ibm2.lab.eng.bos.redhat.com
Installed Product Current Status:
Product Name: Red Hat Enterprise Linux for x86_64 High Touch Beta
Status:       Subscribed

To use Red Hat Insights, install the insights-client package.
To opt out of Red Hat Insights, run "insights-client --unregister" or reregister with "--no-insights".


[root@ibm-x3650m4-01-vm-14 ~]# subscription-manager repo-override --list
This system does not have any content overrides applied to it.    <<<<< returned expected output as no repos overridden here
[root@ibm-x3650m4-01-vm-14 ~]#

[root@ibm-x3650m4-01-vm-14 ~]# subscription-manager repo-override --repo rhel-8-for-x86_64-highavailability-htb-rpms --add enabled:1
[root@ibm-x3650m4-01-vm-14 ~]# subscription-manager repo-override --list
Repository: rhel-8-for-x86_64-highavailability-htb-rpms
  enable: 1                                                       <<<<<<<<<<<<<<< successfully returned list of overrides

[root@ibm-x3650m4-01-vm-14 ~]# yum repolist
Updating Subscription Management repositories.
repo id                                                                         repo name
rhel-8-for-x86_64-appstream-htb-rpms                                            Red Hat Enterprise Linux 8 for x86_64 - AppStream HTB (RPMs)
rhel-8-for-x86_64-baseos-htb-rpms                                               Red Hat Enterprise Linux 8 for x86_64 - BaseOS HTB (RPMs)
rhel-8-for-x86_64-highavailability-htb-rpms                                     Red Hat Enterprise Linux 8 for x86_64 - High Availability HTB (RPMs)
  
                                                                               ^^^^^^^---------repo enabled

[root@ibm-x3650m4-01-vm-14 ~]# subscription-manager unregister
Unregistering from: subscription.rhsm.redhat.com:443/subscription

Verifying on stage server:

[root@ibm-x3650m4-01-vm-14 ~]# subscription-manager register --auto-attach --serverurl=subscription.rhsm.stage.redhat.com
Registering to: subscription.rhsm.stage.redhat.com:443/subscription
Username: stage-ethel
Password: 
The system has been registered with ID: ab757d7b-6dbb-4391-a0f1-823280c06585
The registered system name is: ibm-x3650m4-01-vm-14.ibm2.lab.eng.bos.redhat.com
Installed Product Current Status:
Product Name: Red Hat Enterprise Linux for x86_64 High Touch Beta
Status:       Subscribed

To use Red Hat Insights, install the insights-client package.
To opt out of Red Hat Insights, run "insights-client --unregister" or reregister with "--no-insights".

[root@ibm-x3650m4-01-vm-14 ~]# subscription-manager repo-override --list
This system does not have any content overrides applied to it.
[root@ibm-x3650m4-01-vm-14 ~]# 
[root@ibm-x3650m4-01-vm-14 ~]# subscription-manager repo-override --repo rhel-8-for-x86_64-highavailability-htb-rpms --add enabled:1
[root@ibm-x3650m4-01-vm-14 ~]# subscription-manager repo-override --list
Repository: rhel-8-for-x86_64-highavailability-htb-rpms
  enabled: 1

[root@ibm-x3650m4-01-vm-14 ~]# 


Actual Result: repo-override --list returns expected list

Expected result: repo-override --list should return expected list

Comment 8 errata-xmlrpc 2020-11-04 01:39:41 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 (subscription-manager bug fix and enhancement 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-2020:4460