ubuntu如何升級,如何使用國內的鏡像源

1.如何配置國內源

修改默認源

首先將原配置文件備份
sudo cp /etc/apt/sources.list /etc/apt/sources.list.xxx
然後 VIM 打開,替換

:%s/security.ubuntu/mirrors.aliyun/g
:%s/archive.ubuntu/mirrors.aliyun/g

更新
sudo apt update
再使用 apt install 速度就快多了

2.如何跨版本升級

VIM 打開: /etc/apt/sources.lis
執行下面的命令,artful與bionic分別是新舊版本的名字
%s/artful/bionic/g

sudo apt-get update
sudo apt-get upgrade

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章