yum报错Error: Cannot retrieve repository metadata (repomd.xml) for repository: rhel-source

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了yum报错Error: Cannot retrieve repository metadata (repomd.xml) for repository: rhel-source相关的知识,希望对你有一定的参考价值。

思路:

rm -fr /etc/yum.repo.d/*  #删除下面内容


wget http://mirrors.aliyun.com/repo/Centos-7.repo

wget http://mirrors.aliyun.com/repo/Centos-6.repo   #从三个任一选择一个下载

wget http://mirrors.aliyun.com/repo/Centos-5.repo


yum clean all  #清除

yum makecache  #重新加载缓存

以上是关于yum报错Error: Cannot retrieve repository metadata (repomd.xml) for repository: rhel-source的主要内容,如果未能解决你的问题,请参考以下文章

Centos8 yum 报错 Error: Failed to download metadata for repo 'appstream': Cannot prepare inter

CentOS系统yum源使用报错:Error: Cannot retrieve repository metadata (repomd.xml) for repository: rpmforge.(示

解决yum报错:Error: Cannot retrieve repository metadata (repomd.xml) for repository: base. Please verify

yum报错Error: Cannot retrieve repository metadata (repomd.xml) for repository: rhel-source

错误记录Android Studio 编译报错 ( cannot open this project, please retry with version 4.2 or newer. )

Centos中执行yum update或yum install 时报Error: Cannot find a valid baseurl for repo: base错误