- Invalid configuration value: failovermethod=priority in /etc/yum.repos.d/CentOS-Base.repo; 配置:ID 为 "failovermethod" 的 OptionBinding 不存在
- Invalid configuration value: failovermethod=priority in /etc/yum.repos.d/CentOS-Base.repo; 配置:ID 为 "failovermethod" 的 OptionBinding 不存在
- Invalid configuration value: failovermethod=priority in /etc/yum.repos.d/CentOS-Base.repo; 配置:ID 为 "failovermethod" 的 OptionBinding 不存在
- Invalid configuration value: failovermethod=priority in /etc/yum.repos.d/CentOS-Base.repo; 配置:ID 为 "failovermethod" 的 OptionBinding 不存在
- Invalid configuration value: failovermethod=priority in /etc/yum.repos.d/CentOS-Base.repo; 配置:ID 为 "failovermethod" 的 OptionBinding 不存在
- CentOS-8 - Base - mirrors.aliyun.com 0.0 B/s | 0 B 00:47
- Errors during downloading metadata for repository 'base':
- - Status code: 404 for https://mirrors.aliyun.com/centos/8/BaseOS/x86_64/os/repodata/repomd.xml (IP: 120.39.197.216)
- - Curl error (7): Couldn't connect to server for http://mirrors.aliyuncs.com/centos/8/BaseOS/x86_64/os/repodata/repomd.xml [Failed to connect to mirrors.aliyuncs.com port 80: 拒绝连接]
- 错误:为仓库 'base' 下载元数据失败 : Cannot download repomd.xml: Cannot download repodata/repomd.xml: All mirrors were tried
是因为我之前配置阿里云镜像指令错了,以前是这样的:
- wget -O /etc/yum.repos.d/CentOS-Base.repo https://mirrors.aliyun.com/repo/Centos-8.repo
解决办法
- # 进入yum目录
- cd /etc/yum.repos.d
- # 删除目录下所有文件(注意完整复制,不要漏了那个点)
- rm -rf ./*
- # 安装正确的源
- wget -O /etc/yum.repos.d/CentOS-Base.repo https://mirrors.aliyun.com/repo/Centos-vault-8.5.2111.repo
- # 生成缓存
- yum makecache