Ubuntu系统配置系列1——更新软件源
Ubuntu软件源是国外的,因此下载软件时,速度太慢,所以更换为国内软件源。
本操作以Ubuntu16.04换中科大源为例,若系统为其他版本或者想换为中科大、阿里的源,只需把第三步软件源地址更改即可,具体操作见附件内容。
#1.备份系统自带的国外软件源 sudo cp /etc/apt/sources.list /etc/apt/sources.list.bak_yyyymmdd
#2.用gedit软件打开软件源的配置文件 sudo gedit /etc/apt/sources.list
#3.删除原文件的内容,把中科大的软件源插入(以下是中科大的软件源) # 默认注释了源码仓库,如有需要可自行取消注释 deb https://mirrors.ustc.edu.cn/ubuntu/ xenial main restricted universe multiverse # deb-src https://mirrors.ustc.edu.cn/ubuntu/ xenial main restricted universe multiverse deb https://mirrors.ustc.edu.cn/ubuntu/ xenial-updates main restricted universe multiverse # deb-src https://mirrors.ustc.edu.cn/ubuntu/ xenial-updates main restricted universe multiverse deb https://mirrors.ustc.edu.cn/ubuntu/ xenial-backports main restricted universe multiverse # deb-src https://mirrors.ustc.edu.cn/ubuntu/ xenial-backports main restricted universe multiverse deb https://mirrors.ustc.edu.cn/ubuntu/ xenial-security main restricted universe multiverse # deb-src https://mirrors.ustc.edu.cn/ubuntu/ xenial-security main restricted universe multiverse # 预发布软件源,不建议启用 # deb https://mirrors.ustc.edu.cn/ubuntu/ xenial-proposed main restricted universe multiverse # deb-src https://mirrors.ustc.edu.cn/ubuntu/ xenial-proposed main restricted universe multiverse
#4.更新 sudo apt-get update sudo apt-get upgrade