为了优化ubuntu软件安装/更新速度,我测试了国内几家apt源的速度,发现北京交大的apt源速度相对最快,然后可以通过以下步骤更新ubuntu源

1) 备份默认的apt源

1 $ cd /etc/apt
2 $ sudo cp sources.list sources.list.backup

2) 编辑

$ sudo gedit sources.list

复制粘贴以下列表:

复制代码
 1 deb http://archive.ubuntu.com/ubuntu/ raring main restricted universe multiverse
 2 deb http://archive.ubuntu.com/ubuntu/ raring-security main restricted universe multiverse
 3 deb http://archive.ubuntu.com/ubuntu/ raring-updates main restricted universe multiverse
 4 deb http://archive.ubuntu.com/ubuntu/ raring-proposed main restricted universe multiverse
 5 deb http://archive.ubuntu.com/ubuntu/ raring-backports main restricted universe multiverse
 6 deb-src http://archive.ubuntu.com/ubuntu/ raring main restricted universe multiverse
 7 deb-src http://archive.ubuntu.com/ubuntu/ raring-security main restricted universe multiverse
 8 deb-src http://archive.ubuntu.com/ubuntu/ raring-updates main restricted universe multiverse
 9 deb-src http://archive.ubuntu.com/ubuntu/ raring-proposed main restricted universe multiverse
10 deb-src http://archive.ubuntu.com/ubuntu/ raring-backports main restricted universe multiverse
复制代码

3) 注意,每次修改完apt源,一定要执行一下更新

$ sudo apt-get update

大概花了几分钟,更新完成之后,就可以使用apt来安装应用程序了。

1 对 “更换ubuntu apt-get 源”的想法;

发表评论

邮箱地址不会被公开。 必填项已用*标注