Eswlnk Blog Eswlnk Blog
  • 资源
    • 精彩视频
    • 破解专区
      • WHMCS
      • WordPress主题
      • WordPress插件
    • 其他分享
    • 极惠VPS
    • PDF资源
  • 关于我
    • 论文阅读
    • 关于本站
    • 通知
    • 左邻右舍
    • 玩物志趣
    • 日志
    • 专题
  • 热议话题
    • 游戏资讯
  • 红黑
    • 渗透分析
    • 攻防对抗
    • 代码发布
  • 自主研发
    • 知识库
    • 插件
      • ToolBox
      • HotSpot AI 热点创作
    • 区块
    • 快乐屋
    • 卡密
  • 乱步
    • 文章榜单
    • 热门标签
  • 问答中心反馈
  • 注册
  • 登录
首页 › 其他分享 › 个人经历分享:Debian 12 换源与更新依赖

个人经历分享:Debian 12 换源与更新依赖

Eswlnk的头像
Eswlnk
2023-12-03 22:47:22
个人经历分享:Debian 12 换源与更新依赖-Eswlnk Blog
智能摘要 AI
作者描述了在安装Debian 12时遇到的问题——默认源导致更新卡住,并提供了通过手动更改源来解决的方法。具体步骤包括注释掉默认源并添加新的镜像源,如中国科技大学(USTC)、腾讯、阿里或网易的镜像。这些镜像支持多种版本(bookworm、bookworm-security、bookworm-updates等),涵盖主要组件(main、contrib、non-free、non-free-firmware)。更改完成后,需保存文件并运行`sudo apt-get update`以应用更改。此外,文章还提到了其他可用的国内镜像来源,供用户根据需求选择。

前言:源选择的迷惑

在安装Debian 12时,我们通常可以选择国内的软件源,我本以为这样就足够了,无需手动更换。然而,今天在执行更新命令时,系统竟然卡住了,原因是它开始请求官方源了。突如其来的问题,令人感到有些为难,但好在我们可以通过手动更换源来解决。

个人经历分享:Debian 12 换源与更新依赖-Eswlnk Blog

解决问题的教程:手动更换Debian 12软件源

首先,我们需要打开源文件:/etc/apt/sources.list。你可以选择使用nano编辑器或者通过SSH软件自带的文件管理功能进行修改。接着,将文件中的所有deb和deb-src行都注释掉,即在每行前面加上#号,示例如下:

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

然后,插入你喜欢的新源。我个人比较喜欢中科大的源,所以这里给出一份示例:

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

保存后,运行命令:sudo apt-get upgrade重新拉取一下索引文件,这样就可以使用sudo apt-get upgrade来更新依赖了。

其他源:腾讯、阿里、网易源选择

除了中科大的源外,还有其他一些备选源可供选择,这取决于个人偏好。以下是一些腾讯、阿里和网易的源:

腾讯源:

deb https://mirrors.tencent.com/debian/ bookworm main non-free non-free-firmware contrib
deb-src https://mirrors.tencent.com/debian/ bookworm main non-free non-free-firmware contrib
deb https://mirrors.tencent.com/debian-security/ bookworm-security main
deb-src https://mirrors.tencent.com/debian-security/ bookworm-security main
deb https://mirrors.tencent.com/debian/ bookworm-updates main non-free non-free-firmware contrib
deb-src https://mirrors.tencent.com/debian/ bookworm-updates main non-free non-free-firmware contrib
deb https://mirrors.tencent.com/debian-backports/ bookworm-backports main non-free non-free-firmware contrib
deb-src https://mirrors.tencent.com/debian-backports/ bookworm-backports main non-free non-free-firmware contrib

阿里源:

deb https://mirrors.aliyun.com/debian/ bookworm main non-free non-free-firmware contrib
deb-src https://mirrors.aliyun.com/debian/ bookworm main non-free non-free-firmware contrib
deb https://mirrors.aliyun.com/debian-security/ bookworm-security main
deb-src https://mirrors.aliyun.com/debian-security/ bookworm-security main
deb https://mirrors.aliyun.com/debian/ bookworm-updates main non-free non-free-firmware contrib
deb-src https://mirrors.aliyun.com/debian/ bookworm-updates main non-free non-free-firmware contrib
deb https://mirrors.aliyun.com/debian-backports/ bookworm-backports main non-free non-free-firmware contrib
deb-src https://mirrors.aliyun.com/debian-backports/ bookworm-backports main non-free non-free-firmware contrib

网易源:

deb https://mirrors.163.com/debian/ bookworm main non-free non-free-firmware contrib
deb-src https://mirrors.163.com/debian/ bookworm main non-free non-free-firmware contrib
deb https://mirrors.163.com/debian-security/ bookworm-security main
deb-src https://mirrors.163.com/debian-security/ bookworm-security main
deb https://mirrors.163.com/debian/ bookworm-updates main non-free non-free-firmware contrib
deb-src https://mirrors.163.com/debian/ bookworm-updates main non-free non-free-firmware contrib
deb https://mirrors.163.com/debian-backports/ bookworm-backports main non-free non-free-firmware contrib
deb-src https://mirrors.163.com/debian-backports/ bookworm-backports main non-free non-free-firmware contrib
本站默认网盘访问密码:1166
本站默认网盘访问密码:1166
声明:本站原创文章文字版权归本站所有,转载务必注明作者和出处;本站转载文章仅仅代表原作者观点,不代表本站立场,图文版权归原作者所有。如有侵权,请联系我们删除。
Debian依赖源
0
0
Eswlnk的头像
Eswlnk
一个有点倒霉的研究牲站长
赞赏
「其他分享」私有云搭建之道:虚拟化技术探秘与VMWare引领
上一篇
「技术教程」Windows下AList搭建个性Web共享站点 | 打造属于你的局域网分享平台
下一篇

评论 (0)

请登录以参与评论
现在登录
    发表评论

猜你喜欢

  • 「亲测有效」Google Gemini 学生优惠:解决身份验证和支付卡验证
  • 解决国际版EdgeOne绑卡和手机验证问题
  • 小工具开发之EdgeOne免费计划兑换工具
  • 「其他分享」市面上静态页面服务商比较与推荐:选择最适合您的平台
  • 「图片优化」利用Cloudflare CDN减少回源Bucket流量
Eswlnk的头像

Eswlnk

一个有点倒霉的研究牲站长
1108
文章
319
评论
679
获赞

随便看看

「其他分享」VMware/ESXI 虚拟机安装 黑群晖7.1
2022-08-31 18:14:28
国内注册使用OpenAI人工智能小贴士
2023-02-10 23:10:54
「工具分享」全新的Windows效率利器:Quicker
2022-08-30 12:41:39

文章目录

专题展示

WordPress53

工程实践37

热门标签

360 AI API CDN java linux Nginx PDF PHP python SEO Windows WordPress 云服务器 云服务器知识 代码 免费 安全 安卓 工具 开发日志 微信 微软 手机 插件 攻防 攻防对抗 教程 日志 渗透分析 源码 漏洞 电脑 破解 系统 编程 网站优化 网络 网络安全 脚本 苹果 谷歌 软件 运维 逆向
  • 首页
  • 知识库
  • 地图
Copyright © 2023-2025 Eswlnk Blog. Designed by XiaoWu.
本站CDN由 壹盾安全 提供高防CDN安全防护服务
蜀ICP备20002650号-10
页面生成用时 1.203 秒   |  SQL查询 36 次
本站勉强运行:
友情链接: Eswlnk Blog 网站渗透 倦意博客 特资啦!个人资源分享站 祭夜博客 iBAAO壹宝头条
  • WordPress142
  • 网络安全64
  • 漏洞52
  • 软件52
  • 安全48
现在登录
  • 资源
    • 精彩视频
    • 破解专区
      • WHMCS
      • WordPress主题
      • WordPress插件
    • 其他分享
    • 极惠VPS
    • PDF资源
  • 关于我
    • 论文阅读
    • 关于本站
    • 通知
    • 左邻右舍
    • 玩物志趣
    • 日志
    • 专题
  • 热议话题
    • 游戏资讯
  • 红黑
    • 渗透分析
    • 攻防对抗
    • 代码发布
  • 自主研发
    • 知识库
    • 插件
      • ToolBox
      • HotSpot AI 热点创作
    • 区块
    • 快乐屋
    • 卡密
  • 乱步
    • 文章榜单
    • 热门标签
  • 问答中心反馈