RHEL6.3设置CENTOS6.3 YUM

1. Delete yum
rpm -aq | grep yum|xargs rpm -e –nodeps

2. Download CentOS6.3 yum
i386:
wget http://mirrors.163.com/centos/6.3/os/i386/Packages/yum-3.2.29-30.el6.centos.noarch.rpm
wget http://mirrors.163.com/centos/6.3/os/i386/Packages/yum-metadata-parser-1.1.2-16.el6.i686.rpm
wget http://mirrors.163.com/centos/6.3/os/i386/Packages/yum-plugin-fastestmirror-1.1.30-14.el6.noarch.rpm
wget http://mirrors.163.com/centos/6.3/os/i386/Packages/python-iniparse-0.3.1-2.1.el6.noarch.rpm

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

3. Install CentOS6.3 yum
i386:
rpm -ivh python-iniparse-0.3.1-2.1.el6.noarch.rpm
rpm -ivh yum-metadata-parser-1.1.2-16.el6.i686.rpm
rpm -ivh yum-3.2.29-30.el6.centos.noarch.rpm yum-plugin-fastestmirror-1.1.30-14.el6.noarch.rpm (Must install both at the same time.)

x86_64:
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-30.el6.centos.noarch.rpm yum-plugin-fastestmirror-1.1.30-14.el6.noarch.rpm

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

5. Replace '$releasever' with '6.3′ in CentOS6-Base-163.repo
vi CentOS6-Base-163.repo

6. Finally
yum clean all
yum makecache
yum search vim #test

Reference:
1. http://www.cnblogs.com/zhunian/archive/2012/03/30/2425275.html
2. http://www.linuxde.net/2011/10/1578
3. http://mypanpan.iteye.com/blog/1164635

没有评论: