Ask Your Question
2

How do I disable a particular repo?

asked 2013-02-28 04:01:08 -0600

theOptimizedCoder gravatar image

updated 2014-09-28 11:19:57 -0600

mether gravatar image

I'm running F18. I can see the enabled/disabled repos using :

yum repolist

I can also see all my repos from under :

/etc/yum.repos.d

I also use 'yum extender'. I can uncheck a specific repo from the yumex GUI, but that doesn't seem to get saved/persisted. How do I disable/delete a particular repo?

EDIT: I just realized that I could either just remove the .repo file that I do not need from /etc/yum.repos.d OR edit the .repo file (to disable - change enabled:1 to enabled:0).

edit retag flag offensive close merge delete

Comments

Yes. That is correct.

lnxslck gravatar imagelnxslck ( 2013-02-28 05:12:00 -0600 )edit

Can you please post it as an answer @theOptimizedCoder?

FranciscoD_ gravatar imageFranciscoD_ ( 2013-02-28 05:17:22 -0600 )edit

3 Answers

Sort by ยป oldest newest most voted
2

answered 2013-02-28 09:22:37 -0600

ryanlerch gravatar image

updated 2013-02-28 09:23:35 -0600

Yum repositories are defined on a Fedora machine in the /etc/yum.repos.d/ directory. Typically, each repository has its own .repo file in there. You can either edit the files in this directory or use the "Software" GUI that comes with Fedora. Either way you will need to have root or administrator privileges to disable a repository.

Using the Software GUI tool

  1. Open up the PackageKit GUI (search for "Software" in the overview).
  2. In the Packages menu up the top near activities, choose "Software Sources" image description
  3. In the Software Updates Preferences dialog, choose the Software Sources tab. In this tab, each item in this list is a software repository. Use the checkboxes here to enable and disable repositories. Note that you will be asked for the root or administrator password when enabling or disabling repos. image description

Directly editing a .repo file

If you prefer dealing with the config files directly, you can edit the .repo file directly.

  1. Open up the .repo file. In this example, we are going to disable the "fedora-updates-testing.repo"

    sudo vim /etc/yum.repos.d/fedora-updates-testing.repo

  2. The line enabled= is the one that controls turning a repo on and off. To enable a repo, set this value to enabled=1. To disable a repo, set this value to enabled=0.

edit flag offensive delete link more

Comments

Choosing this as the accepted answer as it provides another way of achieving it as well.

theOptimizedCoder gravatar imagetheOptimizedCoder ( 2013-02-28 11:48:12 -0600 )edit
1

answered 2013-03-01 01:19:49 -0600

Remi gravatar image

Another solution, from the command line, to avoid using a test editor :

yum-config-manager --disable reponame
edit flag offensive delete link more

Comments

1

@Remi, since you have mod, feel free to add this as a third option to my answer

ryanlerch gravatar imageryanlerch ( 2013-03-01 08:03:28 -0600 )edit

is there any gui for kde?

DearDhruv gravatar imageDearDhruv ( 2014-03-26 01:06:07 -0600 )edit

On Fedora 22 and later: dnf config-manager --set-disabled REPO where REPO is the unique repository name (repo id) as shown by dnf repolistdocumentation

basic6 gravatar imagebasic6 ( 2016-12-25 07:18:58 -0600 )edit
1

answered 2013-02-28 05:18:49 -0600

Yes. That is correct. To remove a repository you can either remove the file present at /etc/yum.repos.d or simply editing the repo file and change enabled:1 to enabled:0)

edit flag offensive delete link more

Question Tools

Stats

Asked: 2013-02-28 04:01:08 -0600

Seen: 8,521 times

Last updated: Mar 01 '13