Arch下载官方镜像列表Official mirrors

本文介绍如何在Arch Linux系统中获取最新的官方镜像列表,包括使用pacman-mirrorlist包及手动下载的方法,并提供了一种通过官方网站获取按地区分类的镜像列表的途径。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

Official mirrors

The official Arch Linux mirror list is available from the pacman-mirrorlist package. To get an even more up-to-date list of mirrors, use the Pacman Mirror List Generator page on the main site.
In the unlikely scenario that you are without any configured mirrors and pacman-mirrorlist is not installed, run the following command:

手动下载镜像列表

有时因为系统镜像列表丢失或可读性不强,我们需要从官方网站下载按地区分类的镜像列表,很简单,执行如下命令:

wget -O /etc/pacman.d/mirrorlist https://www.archlinux.org/mirrorlist/all/

转载于:https://www.cnblogs.com/wonux/p/5178082.html

jun@jun-VMware-Virtual-Platform:~$ sudo apt update 命中:1 http://mirrors.aliyun.com/ubuntu jammy InRelease 命中:2 http://mirrors.aliyun.com/ubuntu jammy-security InRelease 命中:3 http://mirrors.aliyun.com/ubuntu jammy-updates InRelease 忽略:4 https://download.mono-project.com/repo/ubuntu stable-noble InRelease 忽略:5 https://download.mono-project.com/repo/ubuntu stable-focal/snapshots/6.8.0.123 InRelease 忽略:6 https://download.mono-project.com/repo/ubuntu stable-focal InRelease 命中:7 http://mirrors.aliyun.com/ubuntu jammy-proposed InRelease 命中:8 http://mirrors.aliyun.com/ubuntu jammy-backports InRelease 命中:9 http://mirrors.tuna.tsinghua.edu.cn/ubuntu noble InRelease 命中:12 https://mirrors.tuna.tsinghua.edu.cn/ubuntu jammy InRelease 命中:10 http://mirrors.tuna.tsinghua.edu.cn/ubuntu noble-updates InRelease 命中:13 https://mirrors.tuna.tsinghua.edu.cn/ubuntu jammy-security InRelease 命中:11 http://mirrors.tuna.tsinghua.edu.cn/ubuntu noble-backports InRelease 命中:14 https://artifacts.elastic.co/packages/7.x/apt stable InRelease 命中:15 http://repo.mysql.com/apt/ubuntu noble InRelease 命中:16 https://mirrors.tuna.tsinghua.edu.cn/ubuntu jammy-updates InRelease 命中:17 https://mirrors.tuna.tsinghua.edu.cn/ubuntu jammy-proposed InRelease 命中:18 https://mirrors.tuna.tsinghua.edu.cn/ubuntu jammy-backports InRelease 命中:19 http://download.onlyoffice.com/repo/debian squeeze InRelease 命中:20 http://security.ubuntu.com/ubuntu noble-security InRelease 命中:21 https://download.docker.com/linux/ubuntu noble InRelease 命中:22 https://deb.nodesource.com/node_16.x nodistro InRelease 命中:23 https://d2nlctn12v279m.cloudfront.net/repo/mono/ubuntu focal InRelease 命中:24 https://packages.redis.io/deb noble InRelease 忽略:4 https://download.mono-project.com/repo/ubuntu stable-noble InRelease 忽略:5 https://download.mono-project.com/repo/ubuntu stable-focal/snapshots/6.8.0.123 InRelease 忽略:6 https://download.mono-project.com/repo/ubuntu stable-focal InRelease 命中:25 https://ppa.launchpadcontent.net/dotnet/backports/ubuntu noble InRelease 忽略:4 https://download.mono-project.com/repo/ubuntu stable-noble InRelease 忽略:5 https://download.mono-project.com/repo/ubuntu stable-focal/snapshots/6.8.0.123 InRelease 忽略:6 https://download.mono-project.com/repo/ubuntu stable-focal InRelease 错误:4 https://download.mono-project.com/repo/ubuntu stable-noble InRelease 无法连接上 download.mono-project.com:443 (13.107.246.73)。 - connect (111: 拒绝连接) 错误:5 https://download.mono-project.com/repo/ubuntu stable-focal/snapshots/6.8.0.123 InRelease 不能连接到 download.mono-project.com:https: 错误:6 https://download.mono-project.com/repo/ubuntu stable-focal InRelease 不能连接到 download.mono-project.com:https: 正在读取软件包列表... 完成 正在分析软件包的依赖关系树... 完成 正在读取状态信息... 完成 有 294 个软件包可以升级。请执行 ‘apt list --upgradable’ 来查看它们。 W: 无法下载 https://download.mono-project.com/repo/ubuntu/dists/stable-noble/InRelease 无法连接上 download.mono-project.com:443 (13.107.246.73)。 - connect (111: 拒绝连接) W: 无法下载 https://download.mono-project.com/repo/ubuntu/dists/stable-focal/snapshots/6.8.0.123/InRelease 不能连接到 download.mono-project.com:https: W: 无法下载 https://download.mono-project.com/repo/ubuntu/dists/stable-focal/InRelease 不能连接到 download.mono-project.com:https: W: 部分索引文件下载失败。如果忽略它们,那将转而使用旧的索引文件。
最新发布
07-21
<think>我们注意到用户在执行 `sudo apt update` 时出现了多个错误,主要与 Mono 项目的软件源有关。错误信息显示无法连接到 download.mono-project.com,导致部分索引文件下载失败。同时,用户系统中混合了多个不同版本的 Ubuntu 源(jammy 和 noble),这可能导致兼容性问题。 ### 问题分析 1. **连接问题**:无法连接到 download.mono-project.com,可能是网络问题、DNS 问题或该服务器暂时不可用。 2. **混合系统版本源**:用户系统似乎是 Ubuntu 22.04 (jammy),但配置了 Ubuntu 24.04 (noble) 的软件源,这会导致不兼容。 3. **过时的 Mono 源配置**:用户配置了多个 Mono 源(包括 stable-noble、stable-focal),这些版本与当前系统可能不匹配。 ### 解决方案 #### 步骤 1: 检查网络连接 ```bash # 测试 download.mono-project.com 的可达性 ping -c 4 download.mono-project.com # 测试 HTTPS 端口 (443) 是否可达 nc -zv download.mono-project.com 443 ``` #### 步骤 2: 修正 Mono 软件源 删除当前错误的 Mono 源,并添加适合当前系统(Ubuntu 22.04 jammy)的源: ```bash # 删除现有的 Mono 源列表文件 sudo rm /etc/apt/sources.list.d/mono-official.list sudo rm /etc/apt/sources.list.d/mono-official-stable.list # 添加正确的 Mono 源(针对 jammy) sudo sh -c 'echo "deb [arch=amd64] https://download.mono-project.com/repo/ubuntu stable-jammy main" > /etc/apt/sources.list.d/mono-official-stable.list' ``` #### 步骤 3: 确保使用正确的密钥 ```bash # 下载并安装 Mono 的 GPG 密钥(新方法) sudo gpg --homedir /tmp --no-default-keyring --keyring /usr/share/keyrings/mono-official-archive-keyring.gpg --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF ``` #### 步骤 4: 更新软件包列表 ```bash # 更新软件包列表 sudo apt update ``` #### 步骤 5: 清理混合版本源 检查 `/etc/apt/sources.list` 和 `/etc/apt/sources.list.d/` 目录下所有文件,确保没有包含 noble(24.04)的源,只保留 jammy(22.04)的源。例如: ```bash # 查找并删除 noble 相关的源 grep -r "noble" /etc/apt/sources.list /etc/apt/sources.list.d/ ``` 对于找到的 noble 源文件,要么删除,要么将其中的 `noble` 替换为 `jammy`(但注意不是所有源都适用于 jammy,需要确认)。 #### 步骤 6: 修复依赖关系 ```bash # 修复依赖关系 sudo apt --fix-broken install sudo apt update sudo apt upgrade ``` ### 备选方案:使用镜像源 如果 download.mono-project.com 访问不稳定,可以使用国内镜像(如清华源): ```bash # 使用清华源替代 sudo sed -i 's|https://download.mono-project.com|https://mirrors.tuna.tsinghua.edu.cn/mono|g' /etc/apt/sources.list.d/mono-official-stable.list ``` ### 验证 ```bash sudo apt update sudo apt install mono-complete ``` §§相关问题§§ 1. 如何快速诊断 Linux 系统中的软件源连接问题? 2. Ubuntu 不同发行版(如 jammy 和 noble)的软件源混用会导致哪些具体问题? 3. 有哪些常用的国内开源软件镜像源可以替代官方源? 4. 如何安全地移除系统中已添加的第三方软件源? 5. 在 APT 包管理器中,如何忽略特定软件源的更新错误?</think>### 解决 "无法下载 Mono 软件源索引" 错误 #### 问题诊断 1. **连接失败原因**: - 无法连接 `download.mono-project.com:443` (错误 111: 拒绝连接) - 混合使用了多个 Ubuntu 版本源(jammy 和 noble) - 存在重复/冲突的 Mono 源配置 2. **关键问题点**: ```bash 错误:4 https://download.mono-project.com/repo/ubuntu stable-noble InRelease 无法连接上 download.mono-project.com:443 (13.107.246.73) ``` #### 完整解决方案 ##### 1. 修正软件源版本 ```bash # 查看系统实际版本 lsb_release -a # 删除不匹配的源 (根据实际版本选择) sudo rm /etc/apt/sources.list.d/mono-official* # 移除所有旧配置 # 添加正确的源 (示例为 Ubuntu 22.04 jammy) echo "deb [arch=amd64] https://download.mono-project.com/repo/ubuntu stable-jammy main" | sudo tee /etc/apt/sources.list.d/mono-official.list ``` ##### 2. 使用国内镜像加速 ```bash # 清华镜像替代方案 sudo sed -i 's/download.mono-project.com/mirrors.tuna.tsinghua.edu.cn\/mono-project/' /etc/apt/sources.list.d/mono-official.list # 或阿里云镜像 sudo sed -i 's/download.mono-project.com/mirrors.aliyun.com\/mono-project/' /etc/apt/sources.list.d/mono-official.list ``` ##### 3. 修复混合源问题 ```bash # 清理无效源 sudo rm /etc/apt/sources.list.d/*noble* # 移除所有 noble 版本源 # 更新源缓存 sudo apt clean sudo rm -rf /var/lib/apt/lists/* sudo apt update ``` ##### 4. 临时解决方案(忽略错误源) ```bash # 创建配置文件 echo 'Acquire::https::download.mono-project.com::Verify-Peer "false";' | sudo tee /etc/apt/apt.conf.d/99mono-fix # 跳过特定源更新 sudo apt update -o Dir::Etc::sourcelist="sources.list.d/mono-official.list" -o Dir::Etc::sourceparts="-" -o APT::Get::List-Cleanup="0" ``` #### 网络连接测试 ```bash # 测试域名解析 host download.mono-project.com # 测试 HTTPS 连接 curl -vI https://download.mono-project.com --resolve download.mono-project.com:443:13.107.246.73 # 检查防火墙 sudo ufw status ```
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值