Error: Cannot retrieve repository metadata (repomd.xml)

created at 10-17-2021 views: 44

yum makecache reported an error:

Error: Cannot retrieve repository metadata (repomd.xml) for repository: epel. Please verify its path and try again

solution

vim /etc/yum.repos.d/epel.repo

Modify the [epel] section in the file, put

enabled=1 changed to enabled=0

[epel]
name=Extra Packages for Enterprise Linux 6 - $basearch
baseurl=http://mirrors.aliyun.com/epel/6/$basearch
failovermethod=priority
enabled=0
gpgcheck=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-6

Then execute: yum makecache

[root@localhost yum.repos.d]# yum makecache
Loaded plugins: fastestmirror, security, upgrade-helper
Repository base is listed more than once in the configuration
Repository extras is listed more than once in the configuration
Determining fastest mirrors
 * webtatic: us-east.repo.webtatic.com
base                                                                                                                                                                                                                                                   | 3.7 kB     00:00     
extras                                                                                                                                                                                                                                                 | 3.4 kB     00:00     
extras/filelists_db                                                                                                                                                                                                                                    |  32 kB     00:00     
extras/prestodelta                                                                                                                                                                                                                                     |  605 B     00:00     
extras/primary_db                                                                                                                                                                                                                                      |  31 kB     00:00     
extras/other_db                                                                                                                                                                                                                                        |  37 kB     00:00     
update                                                                                                                                                                                                                                                 | 3.4 kB     00:00     
update/filelists_db                                                                                                                                                                                                                                    | 5.5 MB     00:00     
update/prestodelta                                                                                                                                                                                                                                     | 266 kB     00:00     
update/primary_db                                                                                                                                                                                                                                      | 8.0 MB     00:00     
update/other_db                                                                                                                                                                                                                                        | 355 kB     00:00     
updates                                                                                                                                                                                                                                                | 3.4 kB     00:00     
updates/filelists_db                                                                                                                                                                                                                                   | 2.8 MB     00:00     
updates/prestodelta                                                                                                                                                                                                                                    | 425 kB     00:00     
updates/primary_db                                                                                                                                                                                                                                     | 4.4 MB     00:00     
updates/other_db                                                                                                                                                                                                                                       |  43 MB     00:04     
upg                                                                                                                                                                                                                                                    | 1.9 kB     00:00     
upg/filelists_db                                                                                                                                                                                                                                       | 130 kB     00:00     
upg/primary_db                                                                                                                                                                                                                                         |  14 kB     00:00     
upg/other_db                                                                                                                                                                                                                                           |  18 kB     00:00     
webtatic                                                                                                                                                                                                                                               | 3.6 kB     00:00     
webtatic/group_gz                                                                                                                                                                                                                                      |  374 B     00:00     
webtatic/filelists_db                                                                                                                                                                                                                                  | 121 kB     00:00     
webtatic/primary_db                                                                                                                                                                                                                                    | 229 kB     00:00     
webtatic/other_db                                                                                                                                                                                                                                      |  60 kB     00:00     
Metadata Cache Created

problem solved.

created at:10-17-2021
edited at: 10-17-2021: