树莓派换源教程 使用下面命令查找树莓派版本bullseye可以理解为树莓派的系统代号(10,11,12都不同,一定要看好自己系统是什么版本)

一、查找自己的树莓派版本

使用下面命令查找树莓派版本

lsb_release -a

 

bullseye可以理解为树莓派的系统代号(10,11,12都不同,一定要看好自己系统是什么版本) 

二、查看树莓派系统架构

使用下面命令查找自己树莓派的系统架构

uname -a

 

 aarch64的地方就是代表系统架构的,我的是aarch64的架构。

 完成上面就可以去清华源网站查找自己对应的清华源了。

三、登录清华源网站查找自己树莓派对应的清华源

 清华源网站:debian | 镜像站使用帮助 | 清华大学开源软件镜像站 | Tsinghua Open Source Mirror

按图所示配置镜像源

将下面的代码复制

deb https://mirrors.tuna.tsinghua.edu.cn/debian/ bookworm main contrib non-free non-free-firmware
deb-src https://mirrors.tuna.tsinghua.edu.cn/debian/ bookworm main contrib non-free non-free-firmware
deb https://mirrors.tuna.tsinghua.edu.cn/debian/ bookworm-updates main contrib non-free non-free-firmware
deb-src https://mirrors.tuna.tsinghua.edu.cn/debian/ bookworm-updates main contrib non-free non-free-firmware
deb https://mirrors.tuna.tsinghua.edu.cn/debian/ bookworm-backports main contrib non-free non-free-firmware
deb-src https://mirrors.tuna.tsinghua.edu.cn/debian/ bookworm-backports main contrib non-free non-free-firmware
deb https://security.debian.org/debian-security bookworm-security main contrib non-free non-free-firmware
deb-src https://security.debian.org/debian-security bookworm-security main contrib non-free non-free-firmware

然后打开控制台输入下面命令:

sudo nano /etc/apt/sources.list

 进入该文件编辑,将里面的内容用清华源的内容覆盖掉,保存退出。(Ctrl+X键入Y,回车保存)

四、更换树莓派软件仓库镜像

 网站:raspberrypi | 镜像站使用帮助 | 清华大学开源软件镜像站 | Tsinghua Open Source Mirror

 方式和上面的一样,选择自己相对应的系统进行配置

sudo nano /etc/apt/sources.list.d/raspi.list

deb https://mirrors.tuna.tsinghua.edu.cn/raspberrypi/ bookworm main

 进入该文件编辑,将里面的内容用清华源的内容覆盖掉,保存退出。

五、更新树莓派系统,完成换源

输入下面命令进行系统更新

至此完成换源操作!

作者:你也喜欢吃香菜嘛原文地址:https://blog.csdn.net/m0_64386340/article/details/140751493

%s 个评论

要回复文章请先登录注册