这一直是我的服务器的一个长期问题。我使用 EPEL 存储库来安装和升级nss
包。但我经常遇到这个问题,它因错误而失败。
STDERR: yum-dump Repository Error: Cannot retrieve repository metadata (repomd.xml) for repository: epel. Please verify its path and try again
服务器/内核,rhel6.6:2.6.32-504.el6.x86_64
这/etc/yum.repo.d/epel.repo
[epel]
name=Extra Packages for Enterprise Linux 6 - $basearch
enabled=1
failovermethod=priority
gpgcheck=1
gpgkey=http://dl.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-6
mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=epel-6&arch=$basearch
sslverify=true
我也有一台服务器,同样可以正常工作。未显示此问题的服务器在以下位置具有可用的存储库缓存:
/var/cache/yum/....
而引发错误的那个没有任何 epel 存储库缓存条目。
使用进行调试
URLGRABBER_DEBUG=1 yum upgrade nss 2> debug.log
2015-04-27 17:44:57,555 attempt 1/None: file:///etc/yum.repos.d/epel.repo
INFO:urlgrabber:attempt 1/None: file:///etc/yum.repos.d/epel.repo
* Closing connection #0
2015-04-27 17:44:57,556 success
INFO:urlgrabber:success
2015-04-27 17:44:57,913 combined options: {
'text' : 'epel/metalink',
'delegate' : {
'bandwidth' : 0,
'cache_openers': True,
'checkfunc' : None,
'close_connection': 0,
'copy_local' : 0,
'data' : None,
'delegate' : None,
'failure_callback': None,
'ftp_headers' : None,
'http_headers' : (),
'interrupt_callback': None,
'keepalive' : True,
'max_header_size': 2097152,
'opener' : None,
'password' : None,
'prefix' : None,
'progress_obj' : <output.YumTextMeter instance at 0x2dc7290>,
'proxies' : None,
'quote' : None,
'range' : None,
'reget' : None,
'retry' : 10,
'retrycodes' : [-1, 2, 4, 5, 6, 7],
'size' : None,
'ssl_ca_cert' : None,
'ssl_cert' : None,
'ssl_cert_type': 'PEM',
'ssl_context' : None,
'ssl_key' : None,
'ssl_key_pass' : None,
'ssl_key_type' : 'PEM',
'ssl_verify_host': True,
'ssl_verify_peer': True,
'text' : None,
'throttle' : 0,
'timeout' : 30.0,
'urlparser' : <urlgrabber.grabber.URLParser instance at 0x2ef0248>,
'user_agent' : 'urlgrabber/3.9.1 yum/3.2.29',
'username' : None,
}
}
DEBUG:urlgrabber:combined options: {
'text' : 'epel/metalink',
'delegate' : {
'bandwidth' : 0,
'cache_openers': True,
'checkfunc' : None,
'close_connection': 0,
'copy_local' : 0,
'data' : None,
'delegate' : None,
'failure_callback': None,
'ftp_headers' : None,
'http_headers' : (),
'interrupt_callback': None,
'keepalive' : True,
'max_header_size': 2097152,
'opener' : None,
'password' : None,
'prefix' : None,
'progress_obj' : <output.YumTextMeter instance at 0x2dc7290>,
'proxies' : None,
'quote' : None,
'range' : None,
'reget' : None,
'retry' : 10,
'retrycodes' : [-1, 2, 4, 5, 6, 7],
'size' : None,
'ssl_ca_cert' : None,
'ssl_cert' : None,
'ssl_cert_type': 'PEM',
'ssl_context' : None,
'ssl_key' : None,
'ssl_key_pass' : None,
'ssl_key_type' : 'PEM',
'ssl_verify_host': True,
'ssl_verify_peer': True,
'text' : None,
'throttle' : 0,
'timeout' : 30.0,
'urlparser' : <urlgrabber.grabber.URLParser instance at 0x2ef0248>,
'user_agent' : 'urlgrabber/3.9.1 yum/3.2.29',
'username' : None,
}
}
2015-04-27 17:44:57,914 attempt 1/10: https://mirrors.fedoraproject.org/metalink?repo=epel-6&arch=x86_64
INFO:urlgrabber:attempt 1/10: https://mirrors.fedoraproject.org/metalink?repo=epel-6&arch=x86_64
2015-04-27 17:44:57,915 opening local file "/var/cache/yum/x86_64/6Server/epel/metalink.xml.tmp" with mode wb
INFO:urlgrabber:opening local file "/var/cache/yum/x86_64/6Server/epel/metalink.xml.tmp" with mode wb
* About to connect() to mirrors.fedoraproject.org port 443 (#0)
* Trying 209.132.181.16... * Timeout
* Trying 140.211.169.196... * Timeout
* Trying 152.19.134.142... * Timeout
* Trying 67.219.144.68... * Timeout
* Trying 66.135.62.187... * Timeout
* Trying 209.132.181.15... * Timeout
* Trying 66.35.62.162... * Timeout
* Trying 67.203.2.67... * Timeout
* connect() timed out!
* Closing connection #0
2015-04-27 17:45:27,945 exception: [Errno 12] Timeout on https://mirrors.fedoraproject.org/metalink?repo=epel-6&arch=x86_64: (28, 'connect() timed out!')
INFO:urlgrabber:exception: [Errno 12] Timeout on https://mirrors.fedoraproject.org/metalink?repo=epel-6&arch=x86_64: (28, 'connect() timed out!')
2015-04-27 17:45:27,946 retrycode (12) not in list [-1, 2, 4, 5, 6, 7], re-raising
INFO:urlgrabber:retrycode (12) not in list [-1, 2, 4, 5, 6, 7], re-raising
Error: Cannot retrieve repository metadata (repomd.xml) for repository: epel. Please verify its path and try again
PS:我已经审核过了这但在这种情况下它没有帮助。
这是我这边的本地网络问题吗?我可以访问服务器超时的网址。