100

This question already has an answer here:

Please let me know how to remove certain repositories in Ubuntu 11.04. I am getting the following errors while updating.

sudo apt-get update

Err http://ppa.launchpad.net natty/main Sources                                   
  404  Not Found
Err http://ppa.launchpad.net natty/main i386 Packages                             
  404  Not Found
......

E: Some index files failed to download. They have been ignored, or old ones used instead.

marked as duplicate by Eric Carvalho, Maythux, David Foerster, kos, muru Apr 23 '15 at 23:08

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

78

You can easily remove software repositories from the "Ubuntu Software Center"

Open "Ubuntu Software Center"
- Edit Menu
--- Select "Software Sources...", enter your password
----- Select tab "Other Software"

From the "Other Software" tab you can add or remove repositories.

  • 1
    There is no Ubuntu Software Center in Ubuntu, there is Ubuntu Software one. There is no Edit menu in it, and there is no section Other software in it. – Dims Aug 15 '17 at 16:44
  • 1
    @Dims go to software and sources instead – Rushat Rai Dec 27 '17 at 6:39
  • @RushatRai Where is software and sources? – Michael Fulton Jun 10 '18 at 22:51
  • 2
    To people following these directions in 2018, just open Software & Updates. You can search for this application the same way we open Ubuntu Software Center in the answer above. – Michael Fulton Jun 10 '18 at 22:56
145

Or from the terminal -

sudo add-apt-repository -r ppa:<ppa to remove>

Or, edit the /etc/apt/sources.list to find your ppa there, and remove from there manually (or automatically).

Or, remove the ppa file from /etc/apt/sources.list.d in newer versions of Ubuntu.

  • @HDave I agree with the underlying sentiment of frustration in your statement (I even +1'd your comment!) - but this is not normal behaviour in the Unix world. This is a case of a bad backward hack, where a contributor couldn't even be bothered to write syntactic sugar to hide away a horrible hack/kludge - and thus present a nicer CL experience :( – Homunculus Reticulli Apr 19 '17 at 11:11
  • I believe this is the better answer because it's easier to automate and works on more platforms and installation types. – Rakaim Feb 15 at 14:52
13

You can use PPa Purge:

PPA Purge can remove a PPA and downgrade all the packages you've installed from that PPA to the official version in the Ubuntu repositories

sudo apt-get install ppa-purge

sudo ppa-purge -d <Ubuntu version> ppa:<the PPA to purge>

via:WebUpd8

Or you can go to Software Sources on the Ubuntu Software Center Edit menu, enter your password, go to the Other tab, look for the PPA you wan to remove, click remove and close, it will ask you to update the repos and done.

  • Is there a way to purge a repository that is not a PPA? – NobbZ Feb 6 '15 at 14:32
  • @NobbZ you can just use Software Sources or edit the sources.list file. – Uri Herrera Feb 8 '15 at 1:17
  • 5
    No, I want to PURGE it. This source has installed some mesa stuff, that is too new and so I can't install other stuff from canonicals repositories any more because of strict version constraints. That repository in question was preconfigured by the laptops manufacturer and I realized this problem far too late. Simply removing or deactivating this repository does not work, since apt keeps all the stuff that was already installed from that repo. – NobbZ Feb 8 '15 at 12:19

Not the answer you're looking for? Browse other questions tagged or ask your own question.