Ubuntu 18 配置阿里云Apt镜像源

标签:,
来源: 老季博客
日期: 2019-11-20
作者: 腾讯云/服务器VPS推荐评测/Vultr
阅读数: 70

国外的Apt源速度过慢,这里记录下如何将Ubuntu默认Apt源为阿里镜像源。

创建source.list文件

sudo -i ; touch /etc/apt/sources.list.d/aliyun.list

设置修改内容

echo '
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-proposed main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ bionic-proposed 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 
' > /etc/apt/sources.list.d/aliyun.list

更新源

apt-get update
链接到文章: https://jiloc.com/46551.html

发表回复

您的电子邮箱地址不会被公开。 必填项已用*标注