在CentOS 8 上执行命令 sudo yum update 时报错:
[root@VM-24-13-centos ~]# sudo yum update
Invalid configuration value: failovermethod=priority in /etc/yum.repos.d/CentOS- Epel.repo; Configuration: OptionBinding with id "failovermethod" does not exist
CentOS Linux 8 - AppStream 91 B/s | 38 B 00:00
Error: Failed to download metadata for repo 'appstream': Cannot prepare internal mirrorlist: No URLs in mirrorlist
事实上我上面是报的两个错误,我们一个个来解决:
第一个问题:#
Configuration: OptionBinding with id “failovermethod” does not exist
看报错我们知道是/etc/yum.repos.d/CentOS-Epel.repo 文件中的 failovermethod=priority 出现问题,我们找到这个文件,对这个字段进行注释:
vim /etc/yum.repos.d/CentOS-Epel.repo
第二个问题:#
Error: Failed to download metadata for repo ‘appstream’: Cannot prepare internal mirrorlist: No URLs in mirrorlist
在这个问题上我卡