夸克之书

  • 首页
  • 科普
  • 笔记
  • .NET/C#
  • 物联网
  • 算法
  • Linux
  • 树莓派
夸克之内,别有洞天
  1. 首页
  2. 树莓派
  3. 正文

树莓派bookworm换源

2019-08-24 21094点热度 5人点赞 2条评论

树莓派在国内更新软件源很慢,可以更换为国内的软件源。

1、更新/etc/apt/sources.list

sudo mv /etc/apt/sources.list /etc/apt/sources.list.bk
sudo nano /etc/apt/sources.list

输入以下内容:

deb http://mirrors.ustc.edu.cn/debian bookworm main contrib non-free non-free-firmware
deb http://mirrors.ustc.edu.cn/debian-security/ bookworm-security main contrib non-free non-free-firmware
deb http://mirrors.ustc.edu.cn/debian bookworm-updates main contrib non-free non-free-firmware

# Uncomment deb-src lines below then 'apt-get update' to enable 'apt-get source'
#deb-src http://mirrors.ustc.edu.cn/debian bookworm main contrib non-free non-free-firmware
#deb-src http://mirrors.ustc.edu.cn/debian-security/ bookworm-security main contrib non-free non-free-firmware
#deb-src http://mirrors.ustc.edu.cn/debian bookworm-updates main contrib non-free non-free-firmware
%title插图%num
sources.list

2、更新/etc/apt/sources.list.d/raspi.list

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

替换为以下内容(或者注释之前的,然后追加)

deb https://mirrors.ustc.edu.cn/archive.raspberrypi.org/debian/ bookworm main
#deb-src https://mirrors.ustc.edu.cn/archive.raspberrypi.org/debian/ bookworm main
%title插图%num
raspi.list

3、更新

依次输入以下命令进行更新。

sudo apt update && sudo apt dist-upgrade

如果需要单独更新EEPROM可以参考:传送门

如果apt update出现错误:The following signatures couldn't be verified because the public key is not available: NO_PUBKEY xxxxxxxxxxxxxxxxxxx

使用以下命令添加KEY:

sudo apt-key adv --recv-keys --keyserver keyserver.ubuntu.com xxxxxxxxxxxxxxxxxxx
本作品采用 知识共享署名-非商业性使用 4.0 国际许可协议 进行许可
标签: 暂无
最后更新:2024-01-14

afirefish

这个人很懒,什么都没留下

打赏 点赞
< 上一篇
下一篇 >

文章评论

  • Billion

    树莓派64位换源以后可能下不了软件,想知道博主有没有解决的办法

    2020-10-03
    登录以回复
    • oh2e

      @Billion 64位镜像可以直接使用debian的系统源,首先需要编辑/etc/apt/sources.list,使用#号注释原内容,然后在末尾添加Debian的系统源:

      # 默认注释了源码镜像以提高 apt update 速度,如有需要可自行取消注释
      deb https://mirrors.tuna.tsinghua.edu.cn/debian/ buster main contrib non-free
      # deb-src https://mirrors.tuna.tsinghua.edu.cn/debian/ buster main contrib non-free
      deb https://mirrors.tuna.tsinghua.edu.cn/debian/ buster-updates main contrib non-free
      # deb-src https://mirrors.tuna.tsinghua.edu.cn/debian/ buster-updates main contrib non-free
      deb https://mirrors.tuna.tsinghua.edu.cn/debian/ buster-backports main contrib non-free
      # deb-src https://mirrors.tuna.tsinghua.edu.cn/debian/ buster-backports main contrib non-free
      deb https://mirrors.tuna.tsinghua.edu.cn/debian-security buster/updates main contrib non-free
      # deb-src https://mirrors.tuna.tsinghua.edu.cn/debian-security buster/updates main contrib non-free
      接着需要配置树莓派官方的软件源,编辑/etc/apt/sources.list.d/raspi.list,同样的,注释原内容,在末尾添加如下内容:

      deb http://mirrors.tuna.tsinghua.edu.cn/raspberrypi/ buster main ui

      系统源和软件源配置完成以后,使用下述两条命令更新:

      sudo apt update
      sudo apt upgrade -y

      2020-11-02
      登录以回复
  • 您需要 登录 之后才可以评论
    放松一下
    https://www.quarkbook.com/wp-content/uploads/2021/05/凤凰传奇-海底(Live).flac
    分类
    • .NET/C#
    • Linux
    • 树莓派
    • 物联网
    • 科普
    • 笔记
    • 算法
    • 默认
    最新 热点 随机
    最新 热点 随机
    在代码中判断龙芯新旧世界平台 Windows获取固定后缀的IPv6地址 目前为止,你可能找不到第二台支持志强的1L小主机(P350 Tiny+W-1350+ECC+双NVME+PCIE扩展)!!! iKuai(爱快)实现成都移动IPTV IPoE拨号 Linux EXT4分区误删除后数据恢复 C#连接到巴法云
    在代码中判断龙芯新旧世界平台
    ESXi 6.7 切换时区(已经确认无效) 国内软件耻辱柱 Steam饥荒专用服务器搭建 简单开始异步编程(1) 批处理器(BAT)自动请求管理员权限 树莓派4B配置U盘启动
    最近评论
    Eagle 发布于 7 个月前(10月21日) 参考博主教程成功搞定了成都移动IPTV组播转单播,电脑、手机都可以播放了。但目前有个问题,原IPTV...
    rundoze 发布于 9 个月前(08月31日) 牛逼
    cc21216695 发布于 2 年前(09月27日) 试了一下,加入启动项也无效,压根没有用
    afirefish 发布于 3 年前(11月28日) 非常感谢,非常棒!
    》随缘《 发布于 3 年前(11月20日) 最新【一键处理】方法: https://github.com/MrXhh/VSTools/rele...
    书签
    • 打赏
    • 毒鸡汤
    • 米店
    • 金鱼直播间

    COPYRIGHT © 2023 quarkbook.com. ALL RIGHTS RESERVED.

    Theme Kratos Made By Seaton Jiang

    蜀ICP备15036129号-9

    登录
    注册|忘记密码?