主頁 > 知識庫 > 給RHEL系統(tǒng)替換軟件更新源的方法

給RHEL系統(tǒng)替換軟件更新源的方法

熱門標簽:bs外呼系統(tǒng) 上海營銷外呼系統(tǒng)定制 常州云呼叫外呼系統(tǒng) 阿克蘇市地圖標注app 長沙人工外呼系統(tǒng)公司 ai人工電話機器人 京東外呼系統(tǒng)怎么操作 河北機器人電銷 小藍鴿電話機器人

RHEL5.X 替換更新源

復制代碼
代碼如下:

cd /etc/yum.repos.d
wget http://docs.linuxtone.org/soft/lemp/CentOS-Base.repo
mv CentOS-Base.repo rhel-debuginfo.repo
rpm --import http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-5

RHEL6.1替換更新源
1.移除Yum

復制代碼
代碼如下:

rpm -aq|grep yum|xargs rpm -e --nodeps

2.下載Yum

復制代碼
代碼如下:

wget http://mirrors.163.com/centos/6.2/os/x86_64/Packages/python-iniparse-0.3.1-2.1.el6.noarch.rpm
wget http://mirrors.163.com/centos/6.2/os/x86_64/Packages/yum-3.2.29-22.el6.centos.noarch.rpm
wget http://mirrors.163.com/centos/6.2/os/x86_64/Packages/yum-metadata-parser-1.1.2-16.el6.x86_64.rpm
wget http://mirrors.163.com/centos/6.2/os/x86_64/Packages/yum-plugin-fastestmirror-1.1.30-10.el6.noarch.rpm


3.安裝Yum

復制代碼
代碼如下:

rpm -ivh python-iniparse-0.3.1-2.1.el6.noarch.rpm
rpm -ivh yum-metadata-parser-1.1.2-16.el6.x86_64.rpm
rpm -ivh yum-3.2.29-22.el6.centos.noarch.rpm yum-plugin-fastestmirror-1.1.30-10.el6.noarch.rpm


4.更新repo文件,使用網易文件
切換目錄到 /etc/yum.repos.d/目錄下

復制代碼
代碼如下:

cd /etc/yum.repos.d/
wget http://mirrors.163.com/.help/CentOS6-Base-163.repo
vi CentOS6-Base-163.repo

編輯文件,把文件里面的$releasever全部替換為版本號,即6 最后保存!或者直接把下面的內存拷貝到CentOS6-Base-163.repo文件中即可(已經修改好)。

復制代碼
代碼如下:

# 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-6 - Base - 163.com
baseurl=http://mirrors.163.com/centos/6/os/$basearch/
#mirrorlist=http://mirrorlist.centos.org/?release=6arch=$basearchrepo=os
gpgcheck=1
gpgkey=http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-6


復制代碼
代碼如下:

#released updates
[updates]
name=CentOS-6 - Updates - 163.com
baseurl=http://mirrors.163.com/centos/6/updates/$basearch/
#mirrorlist=http://mirrorlist.centos.org/?release=6arch=$basearchrepo=updates
gpgcheck=1
gpgkey=http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-6


復制代碼
代碼如下:

#additional packages that may be useful
[extras]
name=CentOS-6 - Extras - 163.com
baseurl=http://mirrors.163.com/centos/6/extras/$basearch/
#mirrorlist=http://mirrorlist.centos.org/?release=6arch=$basearchrepo=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-6 - Plus - 163.com
baseurl=http://mirrors.163.com/centos/6/centosplus/$basearch/
#mirrorlist=http://mirrorlist.centos.org/?release=6arch=$basearchrepo=centosplus
gpgcheck=1
enabled=0
gpgkey=http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-6


復制代碼
代碼如下:

#contrib - packages by Centos Users
[contrib]
name=CentOS-6 - Contrib - 163.com
baseurl=http://mirrors.163.com/centos/6/contrib/$basearch/
#mirrorlist=http://mirrorlist.centos.org/?release=6arch=$basearchrepo=contrib
gpgcheck=1
enabled=0
gpgkey=http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-6

5.最后一步

復制代碼
代碼如下:

yum clean all #清理yum緩存
yum makecache #將服務器上的軟件包信息緩存到本地,以提高搜索安裝軟件的速度。
yum list yum #測試配置的yum源是否已經生效。

標簽:周口 邢臺 甘南 甘孜 來賓 忻州 泉州 銅仁

巨人網絡通訊聲明:本文標題《給RHEL系統(tǒng)替換軟件更新源的方法》,本文關鍵詞  給,RHEL,系統(tǒng),替換,軟件,;如發(fā)現(xiàn)本文內容存在版權問題,煩請?zhí)峁┫嚓P信息告之我們,我們將及時溝通與處理。本站內容系統(tǒng)采集于網絡,涉及言論、版權與本站無關。
  • 相關文章
  • 下面列出與本文章《給RHEL系統(tǒng)替換軟件更新源的方法》相關的同類信息!
  • 本頁收集關于給RHEL系統(tǒng)替換軟件更新源的方法的相關信息資訊供網民參考!
  • 推薦文章