Skip to content

Latest commit

 

History

History
50 lines (31 loc) · 2.26 KB

change-ubuntu-sources.md

File metadata and controls

50 lines (31 loc) · 2.26 KB

为Ubuntu更换国内的软件源

安装了Ubuntu后,运行sudo apt update时感觉速度一下子就慢下来了,是不是很拉跨?

现在就来将Ubuntu默认的软件源更换为国内的来提升 updateinstall的速度!

1.先来打开浏览器,进入TUNA的官方软件园界面

mirrors.tuna.tsinghua.edu.cn_

单击右部中间的使用帮助进入帮助页面并向下滑动找到ubuntu-ports(使用amd64的请进入ubuntu)

mirrors.tuna.tsinghua.edu.cn_help_ubuntu-ports_

选择Ubuntu版本为18.04 LTS后复制下方链接。

使用ssh登录Ubuntu客户端。

后使用

sudo nano /etc/apt/sources.list

image-20200919213017756

将原本存在的行删除,替换为

deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu-ports/ bionic main restricted universe multiverse
# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu-ports/ bionic main restricted universe multiverse
deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu-ports/ bionic-updates main restricted universe multiverse
# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu-ports/ bionic-updates main restricted universe multiverse
deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu-ports/ bionic-backports main restricted universe multiverse
# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu-ports/ bionic-backports main restricted universe multiverse
deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu-ports/ bionic-security main restricted universe multiverse
# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu-ports/ bionic-security main restricted universe multiverse
deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu-ports/ bionic-proposed main restricted universe multiverse
# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu-ports/ bionic-proposed main restricted universe multiverse

image-20200919213303794

保存,退出。

在运行sudo apt update试试

是不是就快很多了呢!