码迷,mamicode.com
首页 > 其他好文 > 详细

1.9 使用CentOS YUM进行更新

时间:2018-07-01 22:02:43      阅读:212      评论:0      收藏:0      [点我收藏+]

标签:oar   使用   x86   erase   centos   fast   安装 centos   1.9   must   

1. 删除原有的RHEL yum

$ rpm -aq | grep yum|xargs rpm --erase –-nodeps

2. 下载 CentOS 5 yum

2.1 i386:

wget http://mirrors.163.com/centos/5/os/i386/CentOS/yum-3.2.22-40.el5.centos.noarch.rpm
wget http://mirrors.163.com/centos/5/os/i386/CentOS/yum-metadata-parser-1.1.2-4.el5.i386.rpm
wget http://mirrors.163.com/centos/5/os/i386/CentOS/yum-fastestmirror-1.1.16-21.el5.centos.noarch.rpm
wget http://mirrors.163.com/centos/5/os/i386/CentOS/python-iniparse-0.2.3-6.el5.noarch.rpm

2.2 x86_64:

wget http://mirrors.163.com/centos/5/os/x86_64/CentOS/yum-3.2.22-40.el5.centos.noarch.rpm
wget http://mirrors.163.com/centos/5/os/x86_64/CentOS/yum-metadata-parser-1.1.2-4.el5.x86_64.rpm
wget http://mirrors.163.com/centos/5/os/x86_64/CentOS/yum-fastestmirror-1.1.16-21.el5.centos.noarch.rpm
wget http://mirrors.163.com/centos/5/os/x86_64/CentOS/python-iniparse-0.2.3-6.el5.noarch.rpm

3. 安装 CentOS5 yum

3.1 i386:

rpm -ivh python-iniparse-0.2.3-6.el5.noarch.rpm
rpm -ivh yum-metadata-parser-1.1.2-4.el5.i386.rpm
rpm -ivh yum-3.2.22-40.el5.centos.noarch.rpm yum-fastestmirror-1.1.16-21.el5.centos.noarch.rpm (Must install both at the same time.)

3.2 x86_64:

rpm -ivh python-iniparse-0.2.3-6.el5.noarch.rpm (如果有冲突,先把已经安装的删除后再安装)
rpm -ivh yum-metadata-parser-1.1.2-4.el5.x86_64.rpm
rpm -ivh yum-3.2.22-40.el5.centos.noarch.rpm yum-fastestmirror-1.1.16-21.el5.centos.noarch.rpm

4. 下载 CentOS6-Base-163.repo 到 /etc/yum.repos.d

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

5. 替换‘$releasever’ 为 ’5′;替换$basesearch为x86_64在 CentOS6-Base-163.repo

vi CentOS6-Base-163.repo
#6. 最后

yum clean all
yum makecache
yum search vim #测试

1.9 使用CentOS YUM进行更新

标签:oar   使用   x86   erase   centos   fast   安装 centos   1.9   must   

原文地址:https://www.cnblogs.com/Justdocument/p/9251416.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!