惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

G
Google Developers Blog
S
Schneier on Security
The Hacker News
The Hacker News
P
Proofpoint News Feed
Spread Privacy
Spread Privacy
L
LINUX DO - 热门话题
L
Lohrmann on Cybersecurity
I
Intezer
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
www.infosecurity-magazine.com
www.infosecurity-magazine.com
Schneier on Security
Schneier on Security
Security Latest
Security Latest
AWS News Blog
AWS News Blog
B
Blog RSS Feed
Microsoft Security Blog
Microsoft Security Blog
有赞技术团队
有赞技术团队
博客园 - 叶小钗
The Last Watchdog
The Last Watchdog
O
OpenAI News
月光博客
月光博客
Hacker News: Ask HN
Hacker News: Ask HN
阮一峰的网络日志
阮一峰的网络日志
S
Security @ Cisco Blogs
Google Online Security Blog
Google Online Security Blog
云风的 BLOG
云风的 BLOG
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
Latest news
Latest news
P
Palo Alto Networks Blog
Last Week in AI
Last Week in AI
M
MIT News - Artificial intelligence
Google DeepMind News
Google DeepMind News
P
Proofpoint News Feed
C
CERT Recently Published Vulnerability Notes
Apple Machine Learning Research
Apple Machine Learning Research
U
Unit 42
PCI Perspectives
PCI Perspectives
博客园 - 聂微东
SecWiki News
SecWiki News
宝玉的分享
宝玉的分享
Forbes - Security
Forbes - Security
H
Heimdal Security Blog
cs.CL updates on arXiv.org
cs.CL updates on arXiv.org
Hugging Face - Blog
Hugging Face - Blog
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
T
Troy Hunt's Blog
博客园 - 三生石上(FineUI控件)
Application and Cybersecurity Blog
Application and Cybersecurity Blog
罗磊的独立博客
WordPress大学
WordPress大学
D
Darknet – Hacking Tools, Hacker News & Cyber Security

无妄当自持

在 RTX 4060 Laptop(8GB 显存)笔记本上部署 Qwen3.5-4B 和 Qwopus3.5-9B-Coder 的完整实战 给 Hermes Agent 接入 Sciverse:5 分钟搞定学术搜索 MCP MinerU:让 AI Agent 读懂 PDF 的文档提取利器 用 Firecrawl + SearXNG 给 Hermes Agent 搭建本地搜索与网页抓取 让服务器的 AI 读写你的 Obsidian 笔记库:从自建同步到 MCP 集成 在 RTX 4060 笔记本上运行 Qwen 3.5 9B:llama.cpp 本地部署实录 在 Fedora 44 上编译支持 CUDA 的 llama.cpp:完整指南 Hermes WebUI 安装与使用指南 Hermes Agent 使用实践:核心机制与命令技巧 小米 MiMo 模型本地部署实践:从选型到踩坑 介绍并初步使用 Hermes Agent Linux 下将浏览器缓存放到内存,并在登录登出时进行同步 在 Fedora server 39 中纯手动部署 Nextcloud 使用 shell 脚本和 systemd 定时替换 Gnome 壁纸 Linux 下字体配置 设置 VirtualBox 虚拟机为静态 ip 以方便主机访问 在启用安全启动的 Fedora 中安装 Nvidia 驱动 曲登尼玛冰川 面向神经科学家的人工神经网络
Fedora 使用脚本配置国内镜像源
insidentally · 2024-03-18 · via 无妄当自持

Fedora 默认使用 Metalink 给出推荐的镜像列表,保证用户使用的镜像仓库足够新,并且能够尽快拿到安全更新,从而提供更好的安全性。所以通常情况下使用默认配置即可,无需更改配置文件。

由于 Metalink 需要从国外的 Fedora 项目服务器上获取元信息,所以对于校园内网、无国外访问等特殊情况,metalink 并不适用,此时可以如下方法修改配置文件。

本脚本在Fedora 36 至 Fedora 39 测试通过

更改 Fedora 镜像源

Fedora 的软件源配置文件可以有多个,其中: 系统默认的 fedora 仓库配置文件为 /etc/yum.repos.d/fedora.repo,系统默认的 updates 仓库配置文件为 /etc/yum.repos.d/fedora-updates.repo。此外还有相应的 modular 仓库。

备份文件

将仓库配置文件备份到 /etc/yum.repos.d/backup 文件夹下。

1
2
3
4
5
6
cd /etc/yum.repos.d/
sudo mkdir backup/
sudo cp fedora.repo backup/
sudo cp fedora-modular.repo backup/
sudo cp fedora-updates.repo backup/
sudo cp fedora-updates-modular.repo backup/

更换清华源

1
2
3
4
5
6
7
sudo sed -e 's|^metalink=|#metalink=|g' \
-e 's|^#baseurl=http://download.example/pub/fedora/linux|baseurl=https://mirrors.tuna.tsinghua.edu.cn/fedora|g' \
-i.bak \
/etc/yum.repos.d/fedora.repo \
/etc/yum.repos.d/fedora-modular.repo \
/etc/yum.repos.d/fedora-updates.repo \
/etc/yum.repos.d/fedora-updates-modular.repo

更新本地缓存

1
sudo dnf makecache

安装 RPM Fusion 并更换清华源

RPM Fusion 为 Fedora/RHEL 提供额外的大量 RPM 软件包的第三方软件源。

安装并启动 RPM Fusion 软件源

1
sudo dnf install --nogpgcheck https://mirrors.tuna.tsinghua.edu.cn/rpmfusion/free/fedora/rpmfusion-free-release-$(rpm -E %fedora).noarch.rpm https://mirrors.tuna.tsinghua.edu.cn/rpmfusion/nonfree/fedora/rpmfusion-nonfree-release-$(rpm -E %fedora).noarch.rpm

备份文件

将仓库配置文件备份到 /etc/yum.repos.d/backup 文件夹下。

1
2
cd /etc/yum.repos.d/
sudo cp rpmfusion-* backup/

修改 rpmfusion 为清华源

1
2
3
4
5
6
7
8
sudo sed -e 's|^metalink=|#metalink=|g' \
-e 's|^#baseurl=http://download1.rpmfusion.org|baseurl=https://mirrors.tuna.tsinghua.edu.cn/rpmfusion|g' \
/etc/yum.repos.d/rpmfusion-free.repo \
/etc/yum.repos.d/rpmfusion-free-updates.repo \
/etc/yum.repos.d/rpmfusion-free-updates-testing.repo \
/etc/yum.repos.d/rpmfusion-nonfree.repo \
/etc/yum.repos.d/rpmfusion-nonfree-updates.repo \
/etc/yum.repos.d/rpmfusion-nonfree-updates-testing.repo

更新本地缓存

1
sudo dnf makecache

补充内容

安装多媒体补充包

1
2
sudo dnf install gstreamer1-plugins-{bad-\*,good-\*,base} gstreamer1-plugin-openh264 gstreamer1-libav --exclude=gstreamer1-plugins-bad-free-devel
sudo dnf install ffmpeg

其他国内镜像源

  1. 清华源:https://mirrors.tuna.tsinghua.edu.cn
  2. 中科大源:https://mirrors.ustc.edu.cn
  3. 阿里云源:https://mirrors.aliyun.com
  4. 腾讯云:https://mirrors.cloud.tencent.com

版权声明: 本博客所有文章除特别声明外,均采用 CC BY-NC-SA 4.0 许可协议。转载请注明来源 无妄当自持


avatar

insidentally

学习、实践、分享