Debian修改APT軟件源

Linux擁有衆多的發行版,每個發行版都有提供鏡像,但是,有些鏡像的下載速度參差不齊,偶爾會有更新失敗的情況。

下面以修改 Debian 軟件源爲 中科大爲例進行說明:

鏡像地址:https://mirrors.ustc.edu.cn/

1、備份原配置文件:

# cp /etc/apt/sources.list /etc/apt/sources.list.backup

2、修改軟件源配置文件

debian 7.x (wheezy)

編輯/etc/apt/sources.list文件, 將內容修改爲:

  1. deb http://mirrors.ustc.edu.cn/debian wheezy main non-free contrib

  2. deb http://mirrors.ustc.edu.cn/debian wheezy-proposed-updates main non-free contrib

  3. deb-src http://mirrors.ustc.edu.cn/debian wheezy main non-free contrib

  4. deb-src http://mirrors.ustc.edu.cn/debian wheezy-proposed-updates main non-free contrib

debian 8.x (jessie) 編輯/etc/apt/sources.list文件, 將內容修改爲:

deb http://mirrors.ustc.edu.cn/debian jessie main non-free contrib
deb http://mirrors.ustc.edu.cn/debian jessie-proposed-updates main non-free contrib
deb-src http://mirrors.ustc.edu.cn/debian jessie main non-free contrib
deb-src http://mirrors.ustc.edu.cn/debian jessie-proposed-updates main non-free contrib

3、更新

# apt-get update

 

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章