centos6.5 yum源報錯

[root@node0002 ~]# yum install man man-pages

Loaded plugins: fastestmirror

YumRepo Error: All mirror URLs are not using ftp, http[s] or file.

Eg. Invalid release/repo/arch combination/

removing mirrorlist with no valid mirrors: /var/cache/yum/x86_64/6/base/mirrorlist.txt

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

yum安裝時吧享,提示以上錯誤猴鲫,百度的結果一般讓替換成163驹碍、阿里的yum源


[root@node0001 yum.repos.d]# yum clean all && yum makecache

Loaded plugins: fastestmirror

Cleaning repos: base extras updates

Cleaning up Everything

Cleaning up list of fastest mirrors

Loaded plugins: fastestmirror

Determining fastest mirrors

http://mirrors.163.com/centos/6.5/os/x86_64/repodata/repomd.xml: [Errno 14] PYCURL ERROR 22 - "The requested URL returned error: 404 Not Found"

Trying other mirror.

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

替換后其實還是會有別的錯誤? ?http://mirrors.163.com/centos/6.6/os/x86_64/repodata/repomd.xml? ?404錯誤

直接打開鏈接可以看到,確實沒有這些頁面够庙,而且目錄下也沒有6.6一下的頁面目錄靠娱,6.6目錄頁下只有readme 文件,內容如下:

This directory (and version of CentOS) is deprecated. For normal users,

you should use /6/ and not /6.6/ in your path. Please see this FAQ

concerning the CentOS release scheme:

https://wiki.centos.org/FAQ/General

If you know what you are doing, and absolutely want to remain at the 6.6

level, go to http://vault.centos.org/ for packages.

Please keep in mind that 6.0, 6.1, 6.2, 6.3, 6.4 , 6.5 and 6.6 no longer gets any updates, nor

any security fix's.

大致意思就是讓你去這里找包就行了:http://vault.centos.org/

打開這個地址可以看到6.5頁面目錄下的層級有os/x86_64/repodata敛纲,進去看到也有repomd.xml文件

直接將163yum源的配置文件內容修改為如下即可:替換內容為加粗部分

# CentOS-Base.repo

#

# The mirror system uses the connecting IP address of the client and the

# update status of each mirror to pick mirrors that are updated to and

# geographically close to the client.? You should use this for CentOS updates

# unless you are manually picking other mirrors.

#

# If the mirrorlist= does not work for you, as a fall back you can try the

# remarked out baseurl= line instead.

#

#

[base]

name=CentOS-$releasever - Base - 163.com

baseurl=https://vault.centos.org/6.5/os/$basearch/

#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=os

gpgcheck=1

gpgkey=http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-6

#released updates

[updates]

name=CentOS-$releasever - Updates - 163.com

baseurl=https://vault.centos.org/6.5/updates/$basearch/

#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=updates

gpgcheck=1

gpgkey=http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-6

#additional packages that may be useful

[extras]

name=CentOS-$releasever - Extras - 163.com

baseurl=https://vault.centos.org/6.5/extras/$basearch/

#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=extras

gpgcheck=1

gpgkey=http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-6

#additional packages that extend functionality of existing packages

[centosplus]

name=CentOS-$releasever - Plus - 163.com

baseurl=https://vault.centos.org/6.5/centosplus/$basearch/

#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=centosplus

gpgcheck=1

enabled=0

gpgkey=http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-6

#contrib - packages by Centos Users

[contrib]

name=CentOS-$releasever - Contrib - 163.com

baseurl=https://vault.centos.org/6.5/contrib/$basearch/

#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=contrib

gpgcheck=1

enabled=0

gpgkey=http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-6


然后執(zhí)行 yum clean all && yum makecache 即可喂击,其他版本按照此思路替換成https://vault.centos.org下的對應版本目錄即可

?著作權歸作者所有,轉載或內容合作請聯(lián)系作者
  • 序言:七十年代末,一起剝皮案震驚了整個濱河市淤翔,隨后出現的幾起案子翰绊,更是在濱河造成了極大的恐慌,老刑警劉巖旁壮,帶你破解...
    沈念sama閱讀 217,509評論 6 504
  • 序言:濱河連續(xù)發(fā)生了三起死亡事件监嗜,死亡現場離奇詭異,居然都是意外死亡寡具,警方通過查閱死者的電腦和手機秤茅,發(fā)現死者居然都...
    沈念sama閱讀 92,806評論 3 394
  • 文/潘曉璐 我一進店門,熙熙樓的掌柜王于貴愁眉苦臉地迎上來童叠,“玉大人框喳,你說我怎么就攤上這事∠锰常” “怎么了五垮?”我有些...
    開封第一講書人閱讀 163,875評論 0 354
  • 文/不壞的土叔 我叫張陵,是天一觀的道長杜秸。 經常有香客問我放仗,道長,這世上最難降的妖魔是什么撬碟? 我笑而不...
    開封第一講書人閱讀 58,441評論 1 293
  • 正文 為了忘掉前任诞挨,我火速辦了婚禮,結果婚禮上呢蛤,老公的妹妹穿的比我還像新娘惶傻。我一直安慰自己,他們只是感情好其障,可當我...
    茶點故事閱讀 67,488評論 6 392
  • 文/花漫 我一把揭開白布银室。 她就那樣靜靜地躺著,像睡著了一般励翼。 火紅的嫁衣襯著肌膚如雪蜈敢。 梳的紋絲不亂的頭發(fā)上,一...
    開封第一講書人閱讀 51,365評論 1 302
  • 那天汽抚,我揣著相機與錄音抓狭,去河邊找鬼。 笑死造烁,一個胖子當著我的面吹牛辐宾,可吹牛的內容都是我干的狱从。 我是一名探鬼主播膨蛮,決...
    沈念sama閱讀 40,190評論 3 418
  • 文/蒼蘭香墨 我猛地睜開眼叠纹,長吁一口氣:“原來是場噩夢啊……” “哼!你這毒婦竟也來了敞葛?” 一聲冷哼從身側響起誉察,我...
    開封第一講書人閱讀 39,062評論 0 276
  • 序言:老撾萬榮一對情侶失蹤,失蹤者是張志新(化名)和其女友劉穎惹谐,沒想到半個月后持偏,有當地人在樹林里發(fā)現了一具尸體,經...
    沈念sama閱讀 45,500評論 1 314
  • 正文 獨居荒郊野嶺守林人離奇死亡氨肌,尸身上長有42處帶血的膿包…… 初始之章·張勛 以下內容為張勛視角 年9月15日...
    茶點故事閱讀 37,706評論 3 335
  • 正文 我和宋清朗相戀三年鸿秆,在試婚紗的時候發(fā)現自己被綠了。 大學時的朋友給我發(fā)了我未婚夫和他白月光在一起吃飯的照片怎囚。...
    茶點故事閱讀 39,834評論 1 347
  • 序言:一個原本活蹦亂跳的男人離奇死亡卿叽,死狀恐怖,靈堂內的尸體忽然破棺而出恳守,到底是詐尸還是另有隱情考婴,我是刑警寧澤,帶...
    沈念sama閱讀 35,559評論 5 345
  • 正文 年R本政府宣布催烘,位于F島的核電站沥阱,受9級特大地震影響,放射性物質發(fā)生泄漏伊群。R本人自食惡果不足惜考杉,卻給世界環(huán)境...
    茶點故事閱讀 41,167評論 3 328
  • 文/蒙蒙 一、第九天 我趴在偏房一處隱蔽的房頂上張望舰始。 院中可真熱鬧崇棠,春花似錦、人聲如沸蔽午。這莊子的主人今日做“春日...
    開封第一講書人閱讀 31,779評論 0 22
  • 文/蒼蘭香墨 我抬頭看了看天上的太陽及老。三九已至抽莱,卻和暖如春,著一層夾襖步出監(jiān)牢的瞬間骄恶,已是汗流浹背食铐。 一陣腳步聲響...
    開封第一講書人閱讀 32,912評論 1 269
  • 我被黑心中介騙來泰國打工, 沒想到剛下飛機就差點兒被人妖公主榨干…… 1. 我叫王不留僧鲁,地道東北人虐呻。 一個月前我還...
    沈念sama閱讀 47,958評論 2 370
  • 正文 我出身青樓象泵,卻偏偏與公主長得像,于是被迫代替她去往敵國和親斟叼。 傳聞我的和親對象是個殘疾皇子偶惠,可洞房花燭夜當晚...
    茶點故事閱讀 44,779評論 2 354

推薦閱讀更多精彩內容