最近在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. 完美解决PYQT5登录界面跳转主界面方法

    该问题,有很多种方法,但是很多方法要么这个有问题,要么那个有问题,最后终于找到一种没问题的方法.记录一下: Login.py(登录窗口)文件 import sys from PyQt5 import ...

  2. c常用函数-strcat 和 strncat

    strcat 和 strncat strcat与strncat都是字符串连接函数,功能上稍有区别: strcat可以把一个字符串的全部内容复制到另一个字符串的后面; strncat则是把一个字符串的指 ...

  3. Android中的SharedPreferences存储

    一.前言 不同于文件的存储方式,SharedPreferences是使用键值对的方式来存储数据的.也就是说,当保存一条数据的时候,需要给这条数据提供一个对应的键,这样在读取数据的时候就可以通过这个键把 ...

  4. opencv C++极坐标变换

    #include<opencv2/core/core.hpp> #include<opencv2/highgui/highgui.hpp> #include<opencv ...

  5. Java并发编程-深入探讨synchronized实现原理

    synchronized这个关键字对应Java程序猿来说是非常的熟悉,只要遇到要解决线程安全问题的地方都会使用这个关键字.接下来一起来探讨一下synchronized到底时怎么实现线程同步,使用syn ...

  6. redis编译报错总结

    redis编译报错总结: 1.不能编译没有GCC 编译工具安装报错:问题1:make时可能会报如下错误cc -c -std=c99 -pedantic -O2 -Wall -W   -g -rdyna ...

  7. Python实用笔记 (11)高级特性——迭代器

    这些可以直接作用于for循环的对象统称为可迭代对象:Iterable. 可以使用isinstance()判断一个对象是否是Iterable对象: >>> from collectio ...

  8. SpringBoot之入门教程-SpringBoot项目搭建

    SpringBoot大大的简化了Spring的配置,把Spring从配置炼狱中解救出来了,以前天天配置Spring和Mybatis,Springmvc,Hibernate等整合在一起,感觉用起来还是挺 ...

  9. Java基础Day07(Map Calender Date 包装类 System类 异常)

    1.Map Map是集合容器,存放的元素有键与值两部分组成,通过键可以找到所对应的值,键和值必须是引用数据类型,键是唯一的,不能重复,没有顺序. HashMap是Map的实现类. Map的添加,删除, ...

  10. 服务认证(JWT)

    上一篇已经讲了微服务组件中的 路由网关(Zuul),但是未介绍服务认证相关,本章主要讲解基于Spring Security 与 JJWT 实现 JWT(JSON Web Token)为接口做授权处理… ...