How to fix "404 Not Found" error with "apt-get update" on old Ubuntu

Last updated on August 3, 2020 by Dan Nanni

Question: I have old Ubuntu 13.04 (Raring Ringtail) installation on my PC. When I run "sudo apt-get update" on it, it throws a bunch of "404 Not Found" errors, and I cannot install or update any package using apt-get or aptitude. Due to this error I cannot even upgrade it to a newer release. How can I fix this problem?

Every Ubuntu release has its end-of-life (EOL) time; regular Ubuntu releases are supported for 18 months, while LTS (Long Term Support) versions are supported up to 3 years (server edition) and 5 years (desktop edition). Once a Ubuntu release has reached EOL, its repositories will no longer be accessible, and you won't get any maintenance updates and security patches from Canonical. As of this writing, Ubuntu 13.04 (Raring Ringtail) has already reached EOL.

If the Ubuntu system you are using is EOL-ed, you will get the following 404 errors from apt-get or aptitude as its repositories have been deprecated.

W: Failed to fetch  404  Not Found [IP: 80]

W: Failed to fetch  404  Not Found

W: Failed to fetch  404  Not Found [IP: 80]

E: Some index files failed to download. They have been ignored, or old ones used instead
W: Failed to fetch  404  Not Found

W: Failed to fetch  404  Not Found

W: Failed to fetch  404  Not Found

W: Failed to fetch  404  Not Found

W: Failed to fetch  404  Not Found

For those users who are using old versions of Ubuntu, Canonical maintains, which is an archive of EOL-ed repositories. Thus, when Canonical's support for your Ubuntu installation ends, you need to switch to repositories maintained at (unless you want to upgrade it before EOL).

Here is a quick way to fix "404 Not Found" errors on old Ubuntu by switching to old-releases repositories.

First, replace main/security repositories with old-releases versions as follows.

$ sudo sed -i -r 's/([a-z]{2}.)?' /etc/apt/sources.list
$ sudo sed -i -r 's/' /etc/apt/sources.list

Then open /etc/apt/sources.list with a text editor, and look for This repository is also no longer supported for EOL-ed releases. So you need to comment out by prepending # sign.

#deb raring main
#deb-src raring main

Now you should be able to install or update packages on an old unsupported Ubuntu release.

Support Xmodulo

This website is made possible by minimal ads and your gracious donation via PayPal or credit card

Please note that this article is published by under a Creative Commons Attribution-ShareAlike 3.0 Unported License. If you would like to use the whole or any part of this article, you need to cite this web page at as the original source.

Xmodulo © 2021 ‒ AboutWrite for UsFeed ‒ Powered by DigitalOcean