ubuntu apt-get更换国内源

1585364631
2023-02-17 / 0 评论 / 373 阅读 / 正在检测是否收录...
温馨提示:
本文最后更新于2023年02月17日,已超过1120天没有更新,若内容或图片失效,请留言反馈。

ubuntu apt-get更换国内源

1.修改sources.list配置文件

vi /etc/apt/sources.list

在首行添加阿里云源

deb http://mirrors.aliyun.com/ubuntu/ bionic main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ bionic-security main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ bionic-updates main restricted universe multiverse
deb 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 main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ bionic-security main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ bionic-updates main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ bionic-proposed main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ bionic-backports main restricted universe multiverse

保存退出

2.更新缓存

apt-get update
apt-get upgrade
0

评论 (0)

取消