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 846207 - multiple specifications of --enable doesnot throw error when repo id is invalid
Summary: multiple specifications of --enable doesnot throw error when repo id is invalid
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: subscription-manager
Version: 6.3
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: rc
: 6.4
Assignee: Alex Wood
QA Contact: Entitlement Bugs
URL:
Whiteboard:
Depends On:
Blocks: 771481
TreeView+ depends on / blocked
 
Reported: 2012-08-07 06:51 UTC by Shwetha Kallesh
Modified: 2013-02-21 08:55 UTC (History)
6 users (show)

Fixed In Version: subscription-manager-1.1.2-1
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-02-21 08:55:33 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2013:0350 0 normal SHIPPED_LIVE subscription-manager bug fix and enhancement update 2013-02-20 20:53:35 UTC

Description Shwetha Kallesh 2012-08-07 06:51:58 UTC
Description of problem:
multiple specifications of --enable doesnot throw error even when repo id is invalid

Version-Release number of selected component (if applicable):
[root@dhcp201-115 ~]# rpm -qa | grep subscription-manager
subscription-manager-migration-data-1.11.2.2-1.git.2.c3c8e22.el5
subscription-manager-firstboot-1.0.12-1.git.36.cb30843.el5
subscription-manager-migration-1.0.12-1.git.36.cb30843.el5
subscription-manager-1.0.12-1.git.36.cb30843.el5
subscription-manager-gui-1.0.12-1.git.36.cb30843.el5


How reproducible:


Steps to Reproduce:
1.[root@dhcp201-115 ~]# subscription-manager repos --enable=awesomeos --enable=awesomeos-ppc 
Repo awesomeos is enabled for this system.


  
Actual results:


Expected results:
Error: A valid repo id is required. Use --list option to see valid repos.


Additional info:

Comment 1 John Sefler 2012-09-19 12:08:13 UTC
In my opinion, I like the valid repos to be enabled/disabled and NOT error out when an invalid repo is encountered.  This is the current behavior.  HOWEVER, the absence of feedback for invalid repos could be improved.  For example:

[root@jsefler-rhel59 ~]# subscription-manager repos --list | grep "Repo Id"
Repo Id:              	content-label-empty-gpg
Repo Id:              	never-enabled-content
Repo Id:              	content-label-no-gpg
Repo Id:              	always-enabled-content
Repo Id:              	content-label
[root@jsefler-rhel59 ~]# subscription-manager repos --enable=content-label-no-gpg --enable=always-enabled-content --enable=FOO --enable=content-label --disable=content-label-empty-gpg --disable=BAR --disable=content-label
Repo content-label-no-gpg is enabled for this system.
Repo always-enabled-content is enabled for this system.
Repo content-label is enabled for this system.
Repo content-label-empty-gpg is disabled for this system.
Repo content-label is disabled for this system.
[root@jsefler-rhel59 ~]# 

Actual Results: above^

Expected Results:

[root@jsefler-rhel59 ~]# subscription-manager repos --enable=content-label-no-gpg --enable=always-enabled-content --enable=FOO --enable=content-label --disable=content-label-empty-gpg --disable=BAR --disable=content-label
Repo content-label-no-gpg is enabled for this system.
Repo always-enabled-content is enabled for this system.
Repo FOO is not entitled on this system. <==================== IMPROVEMENT
Repo content-label is enabled for this system.
Repo content-label-empty-gpg is disabled for this system.
Repo BAR is not entitled on this system. <==================== IMPROVEMENT
Repo content-label is disabled for this system.

Comment 2 Alex Wood 2012-09-20 19:09:47 UTC
commit 174e56ee350584c88289a5188d44809dda6b46a3

Available in subscription-manager-1.1.2-1+

Comment 6 Shwetha Kallesh 2012-11-06 06:25:29 UTC
Verified!!


[root@rhel-64-server ~]# subscription-manager version
server type: Red Hat Subscription Management
subscription management server: 0.7.17-1
subscription-manager: 1.1.5-1.el6
python-rhsm: 1.1.4-1.el6


[root@rhel-64-server ~]# subscription-manager repos --list | grep "Repo Id"
Repo Id:              	awesomeos
Repo Id:              	awesomeos-x86_64
Repo Id:              	awesomeos-modifier
Repo Id:              	awesomeos-ppc
Repo Id:              	always-enabled-content
Repo Id:              	never-enabled-content
Repo Id:              	content-label-empty-gpg
Repo Id:              	awesomeos-s390x
Repo Id:              	content-label-no-gpg
Repo Id:              	awesomeos-ia64
Repo Id:              	awesomeos-ppc64
Repo Id:              	awesomeos-i686
Repo Id:              	content-label
[root@rhel-64-server ~]# subscription-manager repos --enable=content-label-no-gpg --enable=always-enabled-content --enable=FOO --enable=content-label --disable=content-label-empty-gpg --disable=BAR --disable=content-label
Error: FOO is not a valid repo id. Use --list option to see valid repos.
Repo content-label-no-gpg is enabled for this system.
Repo always-enabled-content is enabled for this system.
Repo content-label is enabled for this system.

Comment 8 errata-xmlrpc 2013-02-21 08:55:33 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.

http://rhn.redhat.com/errata/RHBA-2013-0350.html


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