One of the configured repositories failed

本文介绍了如何在Linux系统中使用Yum命令行工具,包括移除epel-release包并更新软件,以及安装新的EPEL发布版。

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

清理现有EPEL配置

# 移除旧版EPEL(强制卸载)
sudo yum remove epel-release -y

清理缓存和元数据

sudo yum clean all
sudo rm -rf /var/cache/yum/*

确认系统版本(关键步骤)

cat /etc/redhat-release
CentOS 7用户需确保系统已更新至最新小版本(如7.9) 
CentOS 8/Stream用户需使用dnf替代yum 

重新安装EPEL

# CentOS 7
sudo yum install https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
# CentOS 8
sudo dnf install https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm

注意:若官方源下载失败,可改用国内镜像(如阿里云):

wget -O /etc/yum.repos.d/epel.repo http://mirrors.aliyun.com/repo/epel-7.repo  # CentOS7
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

SYC_MORE

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

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

余额充值