linux改變apt-get安裝源
最近自己裝了個ubuntu kylin 在使用的過程中發現,系統的apt-get 的源有毛病,總是安裝不了軟件。
感覺應該是傳說中的墻的原因,所以準備換到阿裏雲的源。
下面是步驟:
1、復制原文件備份
sudo cp /etc/apt/source.list /etc/apt/source.list.bak
2、編輯源列表文件
sudo vim /etc/apt/source.list
3、將原來的列表刪除,添加如下內容
deb http://mirrors.aliyun.com/ubuntu/ vivid main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ vivid-security main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ vivid-updates main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ vivid-proposed main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ vivid-backports main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ vivid main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ vivid-security main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ vivid-updates main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ vivid-proposed main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ vivid-backports main restricted universe multiverse
4、運行sudo apt-get update
5、運行sudo apt-get upgrade
以上就完成了對源的更換。
linux改變apt-get安裝源