Ubuntu下 apt-get无法安装软件

突然发现无法使用apt-get install 安装一些东西了

使用apt-get install 时候会提示 E: Unable to locate package xxxx

我的做法是添加源

$sudo gedit /etc/apt/source.list

可以删除里面的所有内容,然后根据你的ubuntu版本,对照下面的列表,把相应的源添加进去

http://ubuntu.srt.cn/

之后再

$ sudo apt-get update

 

/----------------------------------------------由于网络问题,我这边cn99比较快-----------------------------------------------------------/

deb http://ubuntu.cn99.com/ubuntu/ hardy main restricted universe multiverse
deb http://ubuntu.cn99.com/ubuntu/ hardy-security main restricted universe multiverse
deb http://ubuntu.cn99.com/ubuntu/ hardy-updates main restricted universe multiverse
deb http://ubuntu.cn99.com/ubuntu/ hardy-proposed main restricted universe multiverse
deb http://ubuntu.cn99.com/ubuntu/ hardy-backports main restricted universe multiverse
deb-src http://ubuntu.cn99.com/ubuntu/ hardy main restricted universe multiverse
deb-src http://ubuntu.cn99.com/ubuntu/ hardy-security main restricted universe multiverse
deb-src http://ubuntu.cn99.com/ubuntu/ hardy-updates main restricted universe multiverse
deb-src http://ubuntu.cn99.com/ubuntu/ hardy-proposed main restricted universe multiverse
deb-src http://ubuntu.cn99.com/ubuntu/ hardy-backports main restricted universe multiverse

/----------------------------------------------------------------------------------------------------------------------------------------------------------/
Maintainer: bones7456 <bones7456 AT gmail DOT com>

MRTG:welcome to srt mrtg

conent:


You can add these lines to your /etc/apt/sources.list

If you are using Oneiric (11.10):

deb http://ubuntu.srt.cn/ubuntu/ oneiric main restricted universe multiverse
deb http://ubuntu.srt.cn/ubuntu/ oneiric-security main restricted universe multiverse
deb http://ubuntu.srt.cn/ubuntu/ oneiric-updates main restricted universe multiverse
deb http://ubuntu.srt.cn/ubuntu/ oneiric-proposed main restricted universe multiverse
deb http://ubuntu.srt.cn/ubuntu/ oneiric-backports main restricted universe multiverse
deb-src http://ubuntu.srt.cn/ubuntu/ oneiric main restricted universe multiverse
deb-src http://ubuntu.srt.cn/ubuntu/ oneiric-security main restricted universe multiverse
deb-src http://ubuntu.srt.cn/ubuntu/ oneiric-updates main restricted universe multiverse
deb-src http://ubuntu.srt.cn/ubuntu/ oneiric-proposed main restricted universe multiverse
deb-src http://ubuntu.srt.cn/ubuntu/ oneiric-backports main restricted universe multiverse


If you are using Natty (11.04):

deb http://ubuntu.srt.cn/ubuntu/ natty main restricted universe multiverse
deb http://ubuntu.srt.cn/ubuntu/ natty-security main restricted universe multiverse
deb http://ubuntu.srt.cn/ubuntu/ natty-updates main restricted universe multiverse
deb http://ubuntu.srt.cn/ubuntu/ natty-proposed main restricted universe multiverse
deb http://ubuntu.srt.cn/ubuntu/ natty-backports main restricted universe multiverse
deb-src http://ubuntu.srt.cn/ubuntu/ natty main restricted universe multiverse
deb-src http://ubuntu.srt.cn/ubuntu/ natty-security main restricted universe multiverse
deb-src http://ubuntu.srt.cn/ubuntu/ natty-updates main restricted universe multiverse
deb-src http://ubuntu.srt.cn/ubuntu/ natty-proposed main restricted universe multiverse
deb-src http://ubuntu.srt.cn/ubuntu/ natty-backports main restricted universe multiverse


If you are using Maverick (10.10):

deb http://ubuntu.srt.cn/ubuntu/ maverick main restricted universe multiverse
deb http://ubuntu.srt.cn/ubuntu/ maverick-security main restricted universe multiverse
deb http://ubuntu.srt.cn/ubuntu/ maverick-updates main restricted universe multiverse
deb http://ubuntu.srt.cn/ubuntu/ maverick-proposed main restricted universe multiverse
deb http://ubuntu.srt.cn/ubuntu/ maverick-backports main restricted universe multiverse
deb-src http://ubuntu.srt.cn/ubuntu/ maverick main restricted universe multiverse
deb-src http://ubuntu.srt.cn/ubuntu/ maverick-security main restricted universe multiverse
deb-src http://ubuntu.srt.cn/ubuntu/ maverick-updates main restricted universe multiverse
deb-src http://ubuntu.srt.cn/ubuntu/ maverick-proposed main restricted universe multiverse
deb-src http://ubuntu.srt.cn/ubuntu/ maverick-backports main restricted universe multiverse


If you are using Lucid (10.04):

deb http://ubuntu.srt.cn/ubuntu/ lucid main restricted universe multiverse
deb http://ubuntu.srt.cn/ubuntu/ lucid-security main restricted universe multiverse
deb http://ubuntu.srt.cn/ubuntu/ lucid-updates main restricted universe multiverse
deb http://ubuntu.srt.cn/ubuntu/ lucid-proposed main restricted universe multiverse
deb http://ubuntu.srt.cn/ubuntu/ lucid-backports main restricted universe multiverse
deb-src http://ubuntu.srt.cn/ubuntu/ lucid main restricted universe multiverse
deb-src http://ubuntu.srt.cn/ubuntu/ lucid-security main restricted universe multiverse
deb-src http://ubuntu.srt.cn/ubuntu/ lucid-updates main restricted universe multiverse
deb-src http://ubuntu.srt.cn/ubuntu/ lucid-proposed main restricted universe multiverse
deb-src http://ubuntu.srt.cn/ubuntu/ lucid-backports main restricted universe multiverse


If you are using Hardy (8.04):

deb http://ubuntu.srt.cn/ubuntu/ hardy main restricted universe multiverse
deb http://ubuntu.srt.cn/ubuntu/ hardy-security main restricted universe multiverse
deb http://ubuntu.srt.cn/ubuntu/ hardy-updates main restricted universe multiverse
deb http://ubuntu.srt.cn/ubuntu/ hardy-proposed main restricted universe multiverse
deb http://ubuntu.srt.cn/ubuntu/ hardy-backports main restricted universe multiverse
deb-src http://ubuntu.srt.cn/ubuntu/ hardy main restricted universe multiverse
deb-src http://ubuntu.srt.cn/ubuntu/ hardy-security main restricted universe multiverse
deb-src http://ubuntu.srt.cn/ubuntu/ hardy-updates main restricted universe multiverse
deb-src http://ubuntu.srt.cn/ubuntu/ hardy-proposed main restricted universe multiverse
deb-src http://ubuntu.srt.cn/ubuntu/ hardy-backports main restricted universe multiverse


You can find other ubuntu mirrors from
here.

posted @ 2012-10-10 13:13  DecJude  阅读(809)  评论(0)    收藏  举报