添加 ubuntu-sources-22.04.md
This commit is contained in:
parent
e0f0403080
commit
5c55344d61
35
ubuntu-sources-22.04.md
Normal file
35
ubuntu-sources-22.04.md
Normal file
@ -0,0 +1,35 @@
|
|||||||
|
备份 source.list 文件
|
||||||
|
```
|
||||||
|
cp /etc/apt/sources.list /etc/apt/sources.list.bak
|
||||||
|
```
|
||||||
|
```
|
||||||
|
vim /etc/apt/sources.list
|
||||||
|
```
|
||||||
|
|
||||||
|
复制粘贴
|
||||||
|
```
|
||||||
|
deb http://mirrors.aliyun.com/ubuntu/ jammy main restricted universe multiverse
|
||||||
|
deb http://mirrors.aliyun.com/ubuntu/ jammy-updates main restricted universe multiverse
|
||||||
|
deb http://mirrors.aliyun.com/ubuntu/ jammy-backports main restricted universe multiverse
|
||||||
|
deb http://mirrors.aliyun.com/ubuntu/ jammy-security main restricted universe multiverse
|
||||||
|
```
|
||||||
|
|
||||||
|
更新
|
||||||
|
```
|
||||||
|
apt update
|
||||||
|
```
|
||||||
|
|
||||||
|
升级现有软件包(可选)
|
||||||
|
```
|
||||||
|
apt upgrade
|
||||||
|
```
|
||||||
|
|
||||||
|
修改 PPA 和第三方源(如果有的话)
|
||||||
|
```
|
||||||
|
/etc/apt/sources.list.d/
|
||||||
|
```
|
||||||
|
|
||||||
|
替换 ppa 文件的URL,一般将 ppa.launchpad.net 修改为 ppa.mirrors.aliyun.com
|
||||||
|
```
|
||||||
|
deb http://ppa.mirrors.aliyun.com/ppa/username/repositoryname/ jammy main
|
||||||
|
```
|
Loading…
Reference in New Issue
Block a user