最近开始时用debian,突然发现apt是个好东西,以前用rpm总是弄的泪流满面~~
国内比较好用的debian源还是debian.cn99.com,但是不知道什么原因这个国内最快的源挂了,现在设置debian就比较麻烦了。还好有了apt-spy,可以自动测试到哪个源的下载速度最快。
当然,刚装完系统是没有apt-spy的,但是我们可以找个暂时先替代的。譬如:
在/etc/apt/sources.list 中添加
deb [url]http://http.us.debian.org/debian/[/url] stable main
执行以下命令更新软件包列表:
apt-get update
然后执行以下命令安装 apt-spy:
apt-get install apt-spy
当然也可以
[url]www.google.cn[/url]搜索apt-spy安装包
apt-spy update
测试亚洲地区的源的速度,自动写入sources.list
apt-spy -d unstable -a asia -t 5
最后,sources.list中出现
deb
[url]ftp://ftp.debianclub.org/debian/[/url] unstable main #contrib non-free
deb-src [url]ftp://ftp.debianclub.org/debian/[/url] unstable main #contrib non-free
#deb [url]http://security.debian.org/[/url] stable/updates main
deb-src [url]ftp://ftp.debianclub.org/debian/[/url] unstable main #contrib non-free
#deb [url]http://security.debian.org/[/url] stable/updates main
本文出自 “
blog.163.comkinglongno1” 博客,请务必保留此出处
[url]http://67054.blog.51cto.com/57054/128215[/url]