最近在ubuntu 12.10上执行sudo apt-get update 命令后出现了如下错误:

    Ign http://extras.ubuntu.com natty/main TranslationIndex
Err http://extras.ubuntu.com natty/main Sources
Not Found
Err http://extras.ubuntu.com natty/main i386 Packages
Not Found
Ign http://extras.ubuntu.com natty/main Translation-en_US
Err http://security.ubuntu.com natty-security/universe Sources
Not Found [IP: 91.189.92.200 ]
Err http://security.ubuntu.com natty-security/multiverse Sources
Not Found [IP: 91.189.92.200 ]
Ign http://extras.ubuntu.com natty/main Translation-en
Err http://security.ubuntu.com natty-security/universe i386 Packages
Not Found [IP: 91.189.92.200 ]
Err http://security.ubuntu.com natty-security/multiverse i386 Packages
Not Found [IP: 91.189.92.200 ]
Err http://security.ubuntu.com natty-security/main Sources
Not Found [IP: 91.189.92.200 ]
Err http://security.ubuntu.com natty-security/restricted Sources
Not Found [IP: 91.189.92.200 ]
Err http://security.ubuntu.com natty-security/main i386 Packages
Not Found [IP: 91.189.92.200 ]
Err http://security.ubuntu.com natty-security/restricted i386 Packages
Not Found [IP: 91.189.92.200 ]
Ign http://security.ubuntu.com natty-security/main Translation-en_US
Ign http://security.ubuntu.com natty-security/main Translation-en
Ign http://security.ubuntu.com natty-security/multiverse Translation-en_US
Ign http://security.ubuntu.com natty-security/multiverse Translation-en
Ign http://security.ubuntu.com natty-security/restricted Translation-en_US
Ign http://security.ubuntu.com natty-security/restricted Translation-en
Ign http://security.ubuntu.com natty-security/universe Translation-en_US
Ign http://security.ubuntu.com natty-security/universe Translation-en
W: Failed to fetch http://cn.archive.ubuntu.com/ubuntu/dists/natty/main/source/Sources 404 Not Found W: Failed to fetch http://cn.archive.ubuntu.com/ubuntu/dists/natty/restricted/source/Sources 404 Not Found W: Failed to fetch http://cn.archive.ubuntu.com/ubuntu/dists/natty/universe/source/Sources 404 Not Found W: Failed to fetch http://cn.archive.ubuntu.com/ubuntu/dists/natty/multiverse/source/Sources 404 Not Found W: Failed to fetch http://cn.archive.ubuntu.com/ubuntu/dists/natty/main/binary-i386/Packages 404 Not Found W: Failed to fetch http://cn.archive.ubuntu.com/ubuntu/dists/natty/restricted/binary-i386/Packages 404 Not Found W: Failed to fetch http://cn.archive.ubuntu.com/ubuntu/dists/natty/universe/binary-i386/Packages 404 Not Found W: Failed to fetch http://cn.archive.ubuntu.com/ubuntu/dists/natty/multiverse/binary-i386/Packages 404 Not Found W: Failed to fetch http://cn.archive.ubuntu.com/ubuntu/dists/natty-updates/main/source/Sources 404 Not Found W: Failed to fetch http://cn.archive.ubuntu.com/ubuntu/dists/natty-updates/restricted/source/Sources 404 Not Found W: Failed to fetch http://cn.archive.ubuntu.com/ubuntu/dists/natty-updates/universe/source/Sources 404 Not Found W: Failed to fetch http://cn.archive.ubuntu.com/ubuntu/dists/natty-updates/multiverse/source/Sources 404 Not Found W: Failed to fetch http://cn.archive.ubuntu.com/ubuntu/dists/natty-updates/main/binary-i386/Packages 404 Not Found W: Failed to fetch http://cn.archive.ubuntu.com/ubuntu/dists/natty-updates/restricted/binary-i386/Packages 404 Not Found W: Failed to fetch http://cn.archive.ubuntu.com/ubuntu/dists/natty-updates/universe/binary-i386/Packages 404 Not Found W: Failed to fetch http://cn.archive.ubuntu.com/ubuntu/dists/natty-updates/multiverse/binary-i386/Packages 404 Not Found W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/natty-security/universe/source/Sources 404 Not Found [IP: 91.189.92.200 80] W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/natty-security/multiverse/source/Sources 404 Not Found [IP: 91.189.92.200 80] W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/natty-security/universe/binary-i386/Packages 404 Not Found [IP: 91.189.92.200 80] W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/natty-security/multiverse/binary-i386/Packages 404 Not Found [IP: 91.189.92.200 80] W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/natty-security/main/source/Sources 404 Not Found [IP: 91.189.92.200 80] W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/natty-security/restricted/source/Sources 404 Not Found [IP: 91.189.92.200 80] W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/natty-security/main/binary-i386/Packages 404 Not Found [IP: 91.189.92.200 80] W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/natty-security/restricted/binary-i386/Packages 404 Not Found [IP: 91.189.92.200 80] W: Failed to fetch http://extras.ubuntu.com/ubuntu/dists/natty/main/source/Sources 404 Not Found W: Failed to fetch http://extras.ubuntu.com/ubuntu/dists/natty/main/binary-i386/Packages 404 Not Found E: Some index files failed to download. They have been ignored, or old ones used instead.
chaihuasong@chaihuasong:~$ sudo apt-get install git
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package git

发现很多源找不到,需要重新寻找更新源,最后把/etc/apt/sources.list文件中的内容直接替换成:

# deb cdrom:[Ubuntu 15.04 _Vivid Vervet_ - Release i386 ()]/ vivid main restricted

# See http://help.ubuntu.com/community/UpgradeNotes for how to upgrade to
# newer versions of the distribution.
deb http://us.archive.ubuntu.com/ubuntu/ vivid main restricted
deb-src http://us.archive.ubuntu.com/ubuntu/ vivid main restricted ## Major bug fix updates produced after the final release of the
## distribution. ## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu
## team. Also, please note that software in universe WILL NOT receive any
## review or updates from the Ubuntu security team.
deb http://us.archive.ubuntu.com/ubuntu/ vivid universe
deb-src http://us.archive.ubuntu.com/ubuntu/ vivid universe ## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu
## team, and may not be under a free licence. Please satisfy yourself as to
## your rights to use the software. Also, please note that software in
## multiverse WILL NOT receive any review or updates from the Ubuntu
## security team.
deb http://us.archive.ubuntu.com/ubuntu/ vivid multiverse
deb-src http://us.archive.ubuntu.com/ubuntu/ vivid multiverse ## N.B. software from this repository may not have been tested as
## extensively as that contained in the main release, although it includes
## newer versions of some applications which may provide useful features.
## Also, please note that software in backports WILL NOT receive any review
## or updates from the Ubuntu security team.
deb http://us.archive.ubuntu.com/ubuntu/ vivid-backports main restricted universe multiverse
deb-src http://us.archive.ubuntu.com/ubuntu/ vivid-backports main restricted universe multiverse deb http://security.ubuntu.com/ubuntu vivid-security main restricted
deb-src http://security.ubuntu.com/ubuntu vivid-security main restricted
deb http://security.ubuntu.com/ubuntu vivid-security universe
deb-src http://security.ubuntu.com/ubuntu vivid-security universe
deb http://security.ubuntu.com/ubuntu vivid-security multiverse
deb-src http://security.ubuntu.com/ubuntu vivid-security multiverse ## Uncomment the following two lines to add software from Canonical's
## 'partner' repository.
## This software is not part of Ubuntu, but is offered by Canonical and the
## respective vendors as a service to Ubuntu users.
# deb http://archive.canonical.com/ubuntu vivid partner
# deb-src http://archive.canonical.com/ubuntu vivid partner

The solution for apt-get update Err 404的更多相关文章

  1. apt get update无法正常使用解决方案(转载)

    apt get update无法正常使用 解决方法参考博客 [问题描述] 前几天执行apt相关命令(如apt-get update),都会长时间停在``等待报头'',超时后,显示连接超时. 换了快速指 ...

  2. 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 先补齐依 ...

  3. 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 先补齐依 ...

  4. ubuntu下sudo apt-get update Sources 404 Not Found 解决方法

    刚安装了ubuntu之后的主要安装命令无非就是apt-get install了,然而很多都在这里就夭折了. 使用apt-get install ***需要先执行apt-get update 加载文件包 ...

  5. npm install 报错ERR! 404 Not Found: event-stream@3.3.6

    在win下开发的node工程,在linux下用dockerfile部署时,遇到npm install时报错 Step / : RUN npm install ---> Running in 2e ...

  6. 安装xml2js出现npm ERR! code E404 npm ERR! 404 Not Found: event-stream@3.3.6

    原因是npm源指向的问题 执行: npm config set registry https://registry.npmjs.org/

  7. 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 ...

  8. 【ubuntu】更换下载源

    ubuntu,我们在使用apt新装软件的时候,会使用官方的网站去下载软件,但是会因为国内的转接点太多,而导致下载的速度非常慢 ,我们可以通过换成一些中间的节点来进行下载,比如阿里源,中科大源,清华源等 ...

  9. npm 全局执行 update 、 outdated 出现 npm-debug.log 404 错误的问题

    想要执行一次全局更新,发现屡次报错: # npm update -g 提示的错误信息包含如下内容: npm ERR! code E404 npm ERR! 404 Registry returned ...

随机推荐

  1. spring Cloud网关之Spring Cloud Gateway

    Spring Cloud Gateway是什么?(官网地址:https://cloud.spring.io/spring-cloud-gateway/reference/html/) Spring C ...

  2. Adobe Photoshop CC 2019 下载+安装教程

    1. 安装包 链接: https://pan.baidu.com/s/1_w1SjGVjWNJ9nuTqEcaykg 提取码: xatq 2. 打开安装包 运行Set-up,选择语言,位置 ,选择继续 ...

  3. CODING DevOps 系列第一课:基于开源工具链打造持续交付平台

    当下软件发展趋势 当今 IT 行业发展中比较流行的几个技术,首先是微服务化,将原有的一个系统拆分成多个,意味着有多个系统需要构建.测试.部署和运维. 第二个是敏捷开发模式,需求粒度更细化,要求一个可独 ...

  4. DES 加密解密 文件工具类

    public class DESEncrypt { /** 加密工具 */ private Cipher encryptCipher = null; /** 解密工具 */ private Ciphe ...

  5. MySQL实战45讲笔记一

    MySQL的基本架构大体可以分为server层和存储引擎层,逻辑架构图如下: Server层除了图中显示的,还包括所有的内置函数(包括日期.时间.数学和加密函数等),存储过程.触发器.视图等跨存储引擎 ...

  6. JavaWeb网上图书商城完整项目--26.注册页面之验证码换一张实现

    我们现在要实现点击换一张的时候实现验证码的修改 我们首先在html添加函数点击事件: <%@ page language="java" contentType="t ...

  7. 如何修改linux下tomcat指定的jdk路径

    一般情况下,一台服务器只跑一个项目,只需根据所需项目,将linux默认的jdk环境配置好即可.某些时候一台服务器上会跑多个项目,而且各个项目需要的JDK版本各不相同,或者为了使业务独立开来,需要指定T ...

  8. QT5 解析JSON文件

    QT读JSON文件步骤,这里把过程记录一下,网上大多都是怎么写json的,对于读的,记录的不多 首先JSON文件格式必须为UTF-8(非UTF-8 with BOM),UTF-8 with BOM 即 ...

  9. 暑假集训Day2 互不侵犯(状压dp)

    这又是个状压dp (大型自闭现场) 题目大意: 在N*N的棋盘里面放K个国王,使他们互不攻击,共有多少种摆放方案.国王能攻击到它上下左右,以及左上左下右上右下八个方向上附近的各一个格子,共8个格子. ...

  10. webpack4.X + react搭建

    环境准备工作:windows7.webStorm 2017.1.4.Nodejs 8.7.0.npm 5.4.2 PS:安装的时我们都带上版本,这样即便webpack版本发生变化,也不会出现版本问题. ...