ubuntu 的 apt-get update 出现404错误时,ubuntu 版本也 end of life 了的解决方案
xmodulo.com/how-to-fix-apt-get-update-error-on-ubuntu.html
如果是依赖没找到,可以用 sudo apt-get install -f 先补齐依赖看行不行。
1、先使用:
$ sudo rm -rf /var/lib/apt/lists/*
$ sudo apt-get update
如果不行,再使用:
2、
$ sudo rm -R /var/lib/apt/lists/partial/*
$ sudo apt-get update
如果还不行,则
3、
Then check out the "End of Life" date of your Ubuntu release by referring to https://wiki.ubuntu.com/Releases
如果你的ubuntu版本已经 end of life了,则表示不再被支持,即软件库、更新库就不可用了
但是你可以使用 old-releases:
ask.xmodulo.com/404-not-found-error-apt-get-update-ubuntu.html
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 http://us.archive.ubuntu.com/ubuntu/dists/raring-backports/multiverse/binary-i386/Packages 404 Not Found [IP: 91.189.91.13 80] W: Failed to fetch http://extras.ubuntu.com/ubuntu/dists/raring/main/binary-amd64/Packages 404 Not Found W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/raring-security/universe/binary-i386/Packages 404 Not Found [IP: 91.189.88.149 80] E: Some index files failed to download. They have been ignored, or old ones used instead
W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/utopic-security/main/source/Sources 404 Not Found W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/utopic-security/restricted/source/Sources 404 Not Found W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/utopic-security/universe/source/Sources 404 Not Found W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/utopic-security/multiverse/source/Sources 404 Not Found W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/utopic-security/main/binary-amd64/Packages 404 Not Found
For those users who are using old versions of Ubuntu, Canonical maintains old-releases.ubuntu.com, which is an archive of EOL-ed repositories. Thus, when Canonical's support for your Ubuntu installation ends, you need to switch to repositories at old-releases.ubuntu.com (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}\.)?archive.ubuntu.com/old-releases.ubuntu.com/g' /etc/apt/sources.list
$ sudo sed -i -r 's/security.ubuntu.com/old-releases.ubuntu.com/g' /etc/apt/sources.list
Then open /etc/apt/sources.list with a text editor, and look for extras.ubuntu.com. This repository is also no longer supported for 13.04. So you need to comment out extras.ubuntu.com by prepending '#' sign.
#deb http://extras.ubuntu.com/ubuntu raring main
#deb-src http://extras.ubuntu.com/ubuntu raring main
Now you should be able to install or update packages on an old unsupported Ubuntu release.
4、大多数时候采用 sudo add-apt-repository *** 添加的repo source,很多时候在
apt-get update 的时候都会失败,可以这样删掉刚添加的repo:
sudo add-apt-repository ppa:whatever/ppa
sudo apt-get update ....fail..... sudo add-apt-repository --remove ppa:whatever/ppa
ubuntu 的 apt-get update 出现404错误时,ubuntu 版本也 end of life 了的解决方案的更多相关文章
- ubuntu 的 apt-get update 出现404错误时,或者添加ppa失败时,ubuntu 版本也 end of life 了的解决方案
xmodulo.com/how-to-fix-apt-get-update-error-on-ubuntu.html 如果是依赖没找到,可以用 sudo apt-get install -f 先补齐依 ...
- flexpaper上传带中文名字的文档,在页面显示若出现404错误时,请在server.xml文件中进行编码utf-8
flexpaper上传带中文名字的文档,在页面显示若出现404错误时,请在server.xml文件中进行编码utf-8
- ubuntu下sudo apt-get update Sources 404 Not Found 解决方法
刚安装了ubuntu之后的主要安装命令无非就是apt-get install了,然而很多都在这里就夭折了. 使用apt-get install ***需要先执行apt-get update 加载文件包 ...
- ubuntu安装软件失败,出现404错误,更新软件源
更新源方法 备份原来的源 首先备份原来的源,用来出错后进行恢复 sudo cp /etc/apt/sources.list/etc/apt/sources.list_backup 1 如果更新源后出错 ...
- Linux - Ubuntu下执行apt-get update报错:Some index files failed to download. They have been ignored, or old ones used instead.
报错命令 root@ubuntu:/etc/apt# apt-get update Err: http://mirrors.aliyun.com/ubuntu trusty InRelease Cou ...
- Servlet3.0 jsp跳转到Servlet 出现404错误的路径设置方法
最近又遇到了这种问题,百度了好久,发现有人说要在action的路径里面写Servlet文件的绝对路径,比如说,单独打开servlet的地址为http://localhost:8080/TomcatTe ...
- IIS7.0设置404错误页,返回500状态码
一般在II6下,设置自定义404错误页时,只需要在错误页中选择自定义的页面,做自己的404页面即可.但是在IIS7.0及以上时,设置完404错误页后,会发现状态码返回的是500,并且可能会引起页面乱码 ...
- iis设置404错误页,返回500状态码
一般在II6下,设置自定义404错误页时,只需要在错误页中选择自定义的页面,做自己的404页面即可.但是在IIS7.0及以上时,设置完404错误页后,会发现状态码返回的是500,并且可能会引起页面乱码 ...
- ASP.NETCore统一处理404错误都有哪些方式?
当未找到网页并且应用程序返回 404 错误时,ASP.NET Core MVC 仅呈现通用浏览器错误页面,如下图所示 这不是很优雅,是吗? 我们平时看到的404页面一般是这样的 还有这样的 试了下京东 ...
随机推荐
- httpclient 302 重定向
主要是由于页面可能不是通过 request.sendRedirect跳转的,可能通过js location跳转的.所以需要拿跳转后的 地址,重新发送请求...如下所示 if (status == H ...
- python参考手册--第8章
1.模块和import (1)首次import module会做以下3件事: a)创建新的命名空间,用作在该源文件中定义的所有对象的容器.在模块中定义的函数和方法在使用global语句时将访问该命名空 ...
- 16进制字符串转数字(C/C++,VB/VB.net,C#)
这个问题看是很简单,但是在不同语言中实现的方式却千差万别,如果不知道方法,还真是麻烦,我就是在C#中遇到该问题,让我费了很大的周折,才在msdn查到. 一.16进制字符串转数字 1.C/C+ ...
- HDU2896+AC自动机
ac自动机 模板题 /* */ #include<stdio.h> #include<string.h> #include<stdlib.h> #include&l ...
- 【零基础学习iOS开发】【02-C语言】11-函数的声明和定义
在上一讲中,简单介绍了函数的定义和使用,只要你想完成一个新功能,首先想到的应该是定义一个新的函数来完成这个功能.这讲继续介绍函数的其他用法和注意事项. 一.函数的声明 1.在C语言中,函数的定义顺序是 ...
- Android安全问题 抢先拦截短信
同上篇文章一样,这里只陈述结果,代码分析稍后给出 导读:本文叙述如何先于某些伪杀毒软件.病毒.常规软件获取到短信 众所周知,android系统在收到短信息的时候会发送广播,但是此广播是有序广播,也就是 ...
- border-radius的水平和竖直半径
通常我们设置border-radius都只区分四个角的, 如border-radius: 1em 2em. 其实每个角的border-radius都由两部分组成, 水平半径和竖直半径. 要设置水平和竖 ...
- dom4j 的小小测试
@Test public void gogo() throws IOException{ InputStream in = this.getClass().getClassLoader() .getR ...
- forks rate异常
一.收到nagios Current_load报警短信
- NLog 传递参数
用NLog记文件日志,一般都用{$basedir}变量,把日志记在运行的目录或者它的子目录下,遇到要写在其他目录的下,看了下Nlog找到用环境变量传参数. .net 里写 Environment.Se ...