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.
Amended "yum-config-manager" commands
Previously, running the "yum-config-manager --disable" command disabled all configured repositories, while the "yum-config-manager --enable" command did not enable any. This inconsistency has been fixed. The "--disable" and "--enable" commands now require the use of '\*' in the syntax, and "yum-config-manager --enable \*" enables repositories. Running the commands without the addition of '\*' prints a message asking the user to run "yum-config-manager --disable \*" or "yum-config-manager --enable \*" if they want to disable or enable repositories.
Description of problem:
If you execute
yum-config-manager --disable
(yes, no repo name), it happily disables **all** repositories configured in the system. This is not documented in the man page.
If you execute
yum-config-manager --enable
again, without any repo name, it **doesn't** enable all repositories configured on the system.
Version-Release number of selected component (if applicable):
yum-utils-1.1.31-25.el7_0.noarch
Steps to Reproduce:
1. sudo yum-config-manager --disable
2. yum repolist
3. yum-config-manager --enable
4. yum repolist
(Example outputs from CentOS 7 but it's the same in RHEL 7)
Actual results:
yum repolist
Loaded plugins: fastestmirror, langpacks
Loading mirror speeds from cached hostfile
repolist: 0
Expected results:
yum repolist
Loaded plugins: fastestmirror, langpacks
Loading mirror speeds from cached hostfile
* base: centos.hyve.com
* extras: mirror.as29550.net
* updates: mirror.as29550.net
repo id repo name status
!base/7/x86_64 CentOS-7 - Base 8,465
!extras/7/x86_64 CentOS-7 - Extras 44
!updates/7/x86_64 CentOS-7 - Updates 995
repolist: 9,504
Additional info:
man page has no documentation. Also, no error is raised although this is not the documented behavior.
Also, the behavior is not consistent. Since it disables all repos with the --disable, it should enable all repos with --enable as well.
Hi Valentina,
could you please review this requests, I am curious what would be an appropriate "fix" acceptable for upstream? Is it intentional that --disable works as described (undocumented)?
Comment 4Valentina Mukhamedzhanova
2015-04-02 08:56:21 UTC
Running 'yum-config-manager --enable' actually does give an error (although the message is kind of misleading).
if opts.enable and not args:
logger.error("Error: Trying to enable already enabled repos.")
opts.enable = False
I'd say the appropriate fix would be to change this error message, and add the same logic for --disable. We could also suggest using \* to enable/disable all repos.
Comment 6Valentina Mukhamedzhanova
2015-05-26 08:11: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, 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://rhn.redhat.com/errata/RHBA-2015-2129.html
Description of problem: If you execute yum-config-manager --disable (yes, no repo name), it happily disables **all** repositories configured in the system. This is not documented in the man page. If you execute yum-config-manager --enable again, without any repo name, it **doesn't** enable all repositories configured on the system. Version-Release number of selected component (if applicable): yum-utils-1.1.31-25.el7_0.noarch Steps to Reproduce: 1. sudo yum-config-manager --disable 2. yum repolist 3. yum-config-manager --enable 4. yum repolist (Example outputs from CentOS 7 but it's the same in RHEL 7) Actual results: yum repolist Loaded plugins: fastestmirror, langpacks Loading mirror speeds from cached hostfile repolist: 0 Expected results: yum repolist Loaded plugins: fastestmirror, langpacks Loading mirror speeds from cached hostfile * base: centos.hyve.com * extras: mirror.as29550.net * updates: mirror.as29550.net repo id repo name status !base/7/x86_64 CentOS-7 - Base 8,465 !extras/7/x86_64 CentOS-7 - Extras 44 !updates/7/x86_64 CentOS-7 - Updates 995 repolist: 9,504 Additional info: man page has no documentation. Also, no error is raised although this is not the documented behavior. Also, the behavior is not consistent. Since it disables all repos with the --disable, it should enable all repos with --enable as well.