[root@host-10-0-0-9 ~]# yum install httpd
Loaded plugins: fastestmirror, security
Loading mirror speeds from cached hostfile
file:///mnt/cdrom/repodata/repomd.xml: [Errno 14] Could not open/read file:///mnt/cdrom/repodata/repomd.xml
Trying other mirror.
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package httpd.x86_64 0:2.2.15-29.el6.centos will be installed
--> Processing Dependency: httpd-tools = 2.2.15-29.el6.centos for package: httpd-2.2.15-29.el6.centos.x86_64
--> Processing Dependency: apr-util-ldap for package: httpd-2.2.15-29.el6.centos.x86_64
--> Processing Dependency: libaprutil-1.so.0()(64bit) for package: httpd-2.2.15-29.el6.centos.x86_64
--> Processing Dependency: libapr-1.so.0()(64bit) for package: httpd-2.2.15-29.el6.centos.x86_64
--> Running transaction check
---> Package apr.x86_64 0:1.3.9-5.el6_2 will be installed
---> Package apr-util.x86_64 0:1.3.9-3.el6_0.1 will be installed
---> Package apr-util-ldap.x86_64 0:1.3.9-3.el6_0.1 will be installed
---> Package httpd-tools.x86_64 0:2.2.15-29.el6.centos will be installed
--> Finished Dependency Resolution html
Dependencies Resolved centos
================================================================================
Package Arch Version Repository Size
================================================================================
Installing:
httpd x86_64 2.2.15-29.el6.centos c6-media 821 k
Installing for dependencies:
apr x86_64 1.3.9-5.el6_2 c6-media 123 k
apr-util x86_64 1.3.9-3.el6_0.1 c6-media 87 k
apr-util-ldap x86_64 1.3.9-3.el6_0.1 c6-media 15 k
httpd-tools x86_64 2.2.15-29.el6.centos c6-media 73 k this
Transaction Summary
================================================================================
Install 5 Package(s) .net
Total download size: 1.1 M
Installed size: 3.6 M
Is this ok [y/N]: y
Downloading Packages: xml
Error Downloading Packages:
apr-1.3.9-5.el6_2.x86_64: failure: Packages/apr-1.3.9-5.el6_2.x86_64.rpm from c6-media: [Errno 256] No more mirrors to try.
httpd-tools-2.2.15-29.el6.centos.x86_64: failure: Packages/httpd-tools-2.2.15-29.el6.centos.x86_64.rpm from c6-media: [Errno 256] No more mirrors to try.
apr-util-ldap-1.3.9-3.el6_0.1.x86_64: failure: Packages/apr-util-ldap-1.3.9-3.el6_0.1.x86_64.rpm from c6-media: [Errno 256] No more mirrors to try.
httpd-2.2.15-29.el6.centos.x86_64: failure: Packages/httpd-2.2.15-29.el6.centos.x86_64.rpm from c6-media: [Errno 256] No more mirrors to try.
apr-util-1.3.9-3.el6_0.1.x86_64: failure: Packages/apr-util-1.3.9-3.el6_0.1.x86_64.rpm from c6-media: [Errno 256] No more mirrors to try. htm
師妹告訴我,是yum源的問題。解決方法是更換yum源,連接以下:blog
http://blog.csdn.net/ichsonx/article/details/8518420ci
http://blog.csdn.net/ichsonx/article/details/8518631it
更新以後下載,報錯:io
GPG key retrieval failed: [Errno 14] Could not open/read file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5
按照 http://blog.csdn.net/zouhao619/article/details/36870589 的方法將CentOS-Base.repo中的全部RPM-GPG-KEY-CentOS-5更改成RPM-GPG-KEY-CentOS-6並yum makecache後仍報一樣的錯誤。 按照 http://www.cnblogs.com/jackluo/p/3598167.html rpm --import /etc/pki/rpm-gpg/RPM* 成功!