您现在的位置是:首页 > 短信大全

Ubuntu22.04系统更换源操作

作者:焦糖时间:2024-04-17 11:56:25分类:短信大全

简介  文章浏览阅读1.6k次,点赞10次,收藏12次。1、备份原本的Ubuntu22.04系统的软件源文件。2、删除原本的Ubuntu22.04系统软件源。_ubuntu22换源

点击全文阅读

1、备份原本的Ubuntu22.04系统的软件源文件
在这里插入图片描述

sudo cp /etc/apt/sources.list /etc/apt/sources.list.bak

2、删除原本的Ubuntu22.04系统软件源

sudo vim /etc/apt/sources.list  

或者

sudo gedit /etc/apt/sources.list

3、添加软件源
清华源

# 默认注释了源码镜像以提高 apt update 速度,如有需要可自行取消注释deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ jammy main restricted universe multiverse# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ jammy main restricted universe multiversedeb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ jammy-updates main restricted universe multiverse# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ jammy-updates main restricted universe multiversedeb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ jammy-backports main restricted universe multiverse# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ jammy-backports main restricted universe multiversedeb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ jammy-security main restricted universe multiverse# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ jammy-security main restricted universe multiverse# 预发布软件源,不建议启用# deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ jammy-proposed main restricted universe multiverse# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ jammy-proposed main restricted universe multiverse

阿里源

deb http://mirrors.aliyun.com/ubuntu/ jammy main restricted universe multiversedeb-src http://mirrors.aliyun.com/ubuntu/ jammy main restricted universe multiversedeb http://mirrors.aliyun.com/ubuntu/ jammy-security main restricted universe multiversedeb-src http://mirrors.aliyun.com/ubuntu/ jammy-security main restricted universe multiversedeb http://mirrors.aliyun.com/ubuntu/ jammy-updates main restricted universe multiversedeb-src http://mirrors.aliyun.com/ubuntu/ jammy-updates main restricted universe multiversedeb http://mirrors.aliyun.com/ubuntu/ jammy-proposed main restricted universe multiversedeb-src http://mirrors.aliyun.com/ubuntu/ jammy-proposed main restricted universe multiversedeb http://mirrors.aliyun.com/ubuntu/ jammy-backports main restricted universe multiversedeb-src http://mirrors.aliyun.com/ubuntu/ jammy-backports main restricted universe multiverse

中科大源

deb https://mirrors.ustc.edu.cn/ubuntu/ jammy main restricted universe multiversedeb-src https://mirrors.ustc.edu.cn/ubuntu/ jammy main restricted universe multiversedeb https://mirrors.ustc.edu.cn/ubuntu/ jammy-updates main restricted universe multiversedeb-src https://mirrors.ustc.edu.cn/ubuntu/ jammy-updates main restricted universe multiversedeb https://mirrors.ustc.edu.cn/ubuntu/ jammy-backports main restricted universe multiversedeb-src https://mirrors.ustc.edu.cn/ubuntu/ jammy-backports main restricted universe multiversedeb https://mirrors.ustc.edu.cn/ubuntu/ jammy-security main restricted universe multiversedeb-src https://mirrors.ustc.edu.cn/ubuntu/ jammy-security main restricted universe multiversedeb https://mirrors.ustc.edu.cn/ubuntu/ jammy-proposed main restricted universe multiversedeb-src https://mirrors.ustc.edu.cn/ubuntu/ jammy-proposed main restricted universe multiverse

网易源

deb http://mirrors.163.com/ubuntu/ jammy main restricted universe multiversedeb http://mirrors.163.com/ubuntu/ jammy-security main restricted universe multiversedeb http://mirrors.163.com/ubuntu/ jammy-updates main restricted universe multiversedeb http://mirrors.163.com/ubuntu/ jammy-proposed main restricted universe multiversedeb http://mirrors.163.com/ubuntu/ jammy-backports main restricted universe multiversedeb-src http://mirrors.163.com/ubuntu/ jammy main restricted universe multiversedeb-src http://mirrors.163.com/ubuntu/ jammy-security main restricted universe multiversedeb-src http://mirrors.163.com/ubuntu/ jammy-updates main restricted universe multiversedeb-src http://mirrors.163.com/ubuntu/ jammy-proposed main restricted universe multiversedeb-src http://mirrors.163.com/ubuntu/ jammy-backports main restricted universe multiverse

更换成阿里源的图如下所示:
在这里插入图片描述

4、更新源和软件

#更新获取软件源提供的软件列表sudo apt-get update#更新软件sudo apt-get -y upgrade

点击全文阅读

郑重声明:

本站所有活动均为互联网所得,如有侵权请联系本站删除处理

我来说两句