您当前的位置:首页 > 计算机 > 系统应用 > Linux

Ubuntu16.04更换下载源(超简单)

时间:01-24来源:作者:点击数:

Ubuntu16.04更换下载源

  1. 备份原始文件
sudo cp /etc/apt/sources.list /etc/apt/sources.list.backup
  1. 编辑镜像源文件
vim /etc/apt/sources.list

3.将源文件内容全部注释,添加以下内容(更换中科大源):

deb http://mirrors.ustc.edu.cn/ubuntu/ xenial main restricted universe multiverse
deb http://mirrors.ustc.edu.cn/ubuntu/ xenial-security main restricted universe multiverse
deb http://mirrors.ustc.edu.cn/ubuntu/ xenial-updates main restricted universe multiverse
deb http://mirrors.ustc.edu.cn/ubuntu/ xenial-proposed main restricted universe multiverse
deb http://mirrors.ustc.edu.cn/ubuntu/ xenial-backports main restricted universe multiverse
deb-src http://mirrors.ustc.edu.cn/ubuntu/ xenial main restricted universe multiverse
deb-src http://mirrors.ustc.edu.cn/ubuntu/ xenial-security main restricted universe multiverse
deb-src http://mirrors.ustc.edu.cn/ubuntu/ xenial-updates main restricted universe multiverse
deb-src http://mirrors.ustc.edu.cn/ubuntu/ xenial-proposed main restricted universe multiverse
deb-src http://mirrors.ustc.edu.cn/ubuntu/ xenial-backports main restricted universe multiverse

deb [arch=x86_64] https://mirrors.ustc.edu.cn/docker-ce/linux/ubuntu xenial stable
# deb-src [arch=x86_64] https://mirrors.ustc.edu.cn/docker-ce/linux/ubuntu xenial stable
deb [arch=x86_64] https://download.docker.com/linux/ubuntu xenial stable
# deb-src [arch=x86_64] https://download.docker.com/linux/ubuntu xenial stable
deb [arch=amd64] https://download.docker.com/linux/ubuntu xenial stable
# deb-src [arch=amd64] https://download.docker.com/linux/ubuntu xenial stable
deb [arch=amd64] https://mirrors.ustc.edu.cn/docker-ce/linux/ubuntu/ xenial stable
# deb-src [arch=amd64] https://mirrors.ustc.edu.cn/docker-ce/linux/ubuntu/ xenial stable

4.保存:Esc+:wq!

5.更新源

sudo apt-get update
  1. 更新软件
sudo apt-get dist-upgrade
sudo apt-get upgrade
方便获取更多学习、工作、生活信息请关注本站微信公众号城东书院 微信服务号城东书院 微信订阅号
推荐内容
相关内容
栏目更新
栏目热门