修改Ubuntu默认apt下载源

Posted 叶家伟的博客

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了修改Ubuntu默认apt下载源相关的知识,希望对你有一定的参考价值。

修改Ubuntu默认apt下载源

默认下载源很慢,改成阿里的下载速度超快
sudo vim /etc/apt/sources.list

将文件内容替换成

deb http://mirrors.aliyun.com/ubuntu/ bionic main restricted universe multiverse

deb-src http://mirrors.aliyun.com/ubuntu/ bionic main restricted universe multiverse

deb http://mirrors.aliyun.com/ubuntu/ bionic-security main restricted universe multiverse

deb-src http://mirrors.aliyun.com/ubuntu/ bionic-security main restricted universe multiverse

deb http://mirrors.aliyun.com/ubuntu/ bionic-updates main restricted universe multiverse

deb-src http://mirrors.aliyun.com/ubuntu/ bionic-updates main restricted universe multiverse

deb http://mirrors.aliyun.com/ubuntu/ bionic-backports main restricted universe multiverse

deb-src http://mirrors.aliyun.com/ubuntu/ bionic-backports main restricted universe multiverse

deb http://mirrors.aliyun.com/ubuntu/ bionic-proposed main restricted universe multiverse

deb-src http://mirrors.aliyun.com/ubuntu/ bionic-proposed main restricted universe multiverse

更新
sudo apt-get update
sudo apt-get upgrade

以上是关于修改Ubuntu默认apt下载源的主要内容,如果未能解决你的问题,请参考以下文章

Ubuntu 18.04修改默认源

Ubuntu 18.04修改默认源为国内源

Ubuntu 18.04修改默认源为国内源

Ubuntu 18.04 修改默认源为国内源

apt-get下载慢等;修改下载源

怎么让ubuntu的apt-get下载得更快?怎么更换源?