yum install: [Errno 14] problem making ssl connection

Centos 6.4 下配置了epel源,最近发现 yum install 时报错:

Downloading Packages:
http://download.fedoraproject.org/pub/epel/6/x86_64/Django14-1.4.21-1.el6.noarch.rpm: [Errno 14] problem making ssl connection
Trying other mirror.
(2/21): apr-1.3.9-5.el6_2.x86_64.rpm                                                                                         | 123 kB     00:00     
(3/21): apr-util-1.3.9-3.el6_0.1.x86_64.rpm                                                                                  |  87 kB     00:00     
(4/21): apr-util-ldap-1.3.9-3.el6_0.1.x86_64.rpm                                                                             |  15 kB     00:00     
(5/21): dejavu-sans-fonts-2.33-1.el6.noarch.rpm                                                                              | 2.2 MB     00:00     
(6/21): dejavu-serif-fonts-2.33-1.el6.noarch.rpm                                                                             | 951 kB     00:00     
(7/21): graphite-web-0.9.16-1.el6.noarch.rpm                                                                                 | 1.9 MB     00:00     
(8/21): httpd-2.2.15-60.el6.centos.4.x86_64.rpm                                                                              | 839 kB     00:00     
(9/21): httpd-tools-2.2.15-60.el6.centos.4.x86_64.rpm                                                                        |  80 kB     00:00     
(10/21): mod_wsgi-3.2-7.el6.x86_64.rpm                                                                                       |  66 kB     00:00     
(11/21): pyOpenSSL-0.13.1-2.el6.x86_64.rpm                                                                                   | 263 kB     00:00     
(12/21): pycairo-1.8.6-2.1.el6.x86_64.rpm                                                                                    | 172 kB     00:00     
(13/21): pyparsing-1.5.6-1.el6.noarch.rpm                                                                                    |  94 kB     00:00     
http://download.fedoraproject.org/pub/epel/6/x86_64/python-carbon-0.9.16-1.el6.noarch.rpm: [Errno 14] problem making ssl connection
Trying other mirror.
http://download.fedoraproject.org/pub/epel/6/x86_64/python-django-tagging-0.3.1-7.el6.noarch.rpm: [Errno 14] problem making ssl connection
Trying other mirror.
(16/21): python-simplejson-2.0.9-3.1.el6.x86_64.rpm                                                                          | 126 kB     00:00     
(17/21): python-twisted-core-8.2.0-4.el6.x86_64.rpm                                                                          | 2.0 MB     00:00     

解决办法1

yum install ca-certificates

解决方法2

使用阿里云的 mirror: https://mirrors.aliyun.com/epel/

将下面的内容保存到路径 /etc/yum.repos.d/epel.repo 即可。

[epel]
name=Extra Packages for Enterprise Linux 6 - $basearch
baseurl=https://mirrors.ustc.edu.cn/epel/6/$basearch
failovermethod=priority
enabled=1
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-6

发表评论

电子邮件地址不会被公开。 必填项已用*标注