woff 發表於 2017-4-15 03:17:10

yum安裝套件報錯訊息

新系統centos6.5,按照之前的方法安裝epel source:http :
//www.52os.net/articles/apache-rRedirecting-base-on-geoip.html

後無論安裝什麼軟件都會報錯:

# yum install ansible Loaded plugins: fastestmirror,
refresh-packagekit, security Loading mirror speeds from cached
hostfile Error: Cannot retrieve metalink for repository: epel. Please
verify its path and try again

google了一下,解決方法:
編輯:/etc/yum.repos.d/epel.repo
將所有的

#baseurl=http://download.fedoraproject.org/pub/epel/6/$basearch       mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=epel-6&arch=$basearch

取消所有的baseurl的註釋,並註釋掉mirrorlist即可。
之後yum makecache。

參考文章:
http : //www.rackspace.com/knowledge_center/article/installing-rhel-epel-repo-on-centos-5x-or-6x
http://teddysun.com/153.html
頁: [1]
查看完整版本: yum安裝套件報錯訊息