RHEL4通过yum自动升级(使用网易repo源)


需要安装的RPM包

sqlite-3.3.6-2.i386.rpm
python-elementtree-1.2.6-5.el4.centos.i386.rpm
python-sqlite-1.1.7-1.2.1.i386.rpm
python-urlgrabber-2.9.8-2.noarch.rpm
yum-metadata-parser-1.0-8.el4.centos.i386.rpm
centos-yumconf-4-4.5.noarch.rpm
yum-2.4.3-4.el4.centos.noarch.rpm

下载地址

wget http://mirrors.kernel.org/centos/4/os/i386/CentOS/RPMS/python-elementtree-1.2.6-5.el4.centos.i386.rpm
wget http://mirrors.kernel.org/centos/4/os/i386/CentOS/RPMS/python-sqlite-1.1.7-1.2.1.i386.rpm
wget http://mirrors.kernel.org/centos/4/os/i386/CentOS/RPMS/python-urlgrabber-2.9.8-2.noarch.rpm
wget http://mirrors.kernel.org/centos/4/os/i386/CentOS/RPMS/yum-2.4.3-4.el4.centos.noarch.rpm
wget http://mirrors.kernel.org/centos/4/os/i386/CentOS/RPMS/sqlite-3.3.6-2.i386.rpm
wget http://mirrors.kernel.org/centos/4/os/i386/CentOS/RPMS/yum-metadata-parser-1.0-8.el4.centos.i386.rpm
wget ftp://ftp.isu.edu.tw/pub/Linux/CentOS/4.8/os/ia64/CentOS/RPMS/centos-yumconf-4-4.5.noarch.rpm

按顺序安装

rpm -ivh sqlite-3.3.6-2.i386.rpm python-elementtree-1.2.6-5.el4.centos.i386.rpm python-sqlite-1.1.7-1.2.1.i386.rpm python-urlgrabber-2.9.8-2.noarch.rpm yum-metadata-parser-1.0-8.el4.centos.i386.rpm centos-yumconf-4-4.5.noarch.rpm yum-2.4.3-4.el4.centos.noarch.rpm
rm -rf /etc/yum.repos.d/*

vi /etc/yum.conf

[main]
cachedir=/var/cache/yum
debuglevel=2
logfile=/var/log/yum.log
pkgpolicy=newest
distroverpkg=redhat-release
tolerant=1
exactarch=1

[base]
name=CentOS-$releasever – Base
baseurl=http://mirrors.163.com/centos/4/os/i386/
gpgcheck=1

[updates]
name=CentOS-$releasever – Updates
baseurl=http://mirrors.163.com/centos/4/updates/i386/
gpgcheck=1

[addons]
name=CentOS-$releasever - Addons
baseurl=http://mirrors.163.com/centos/4/addons/i386/
gpgcheck=1

[extras]
name=CentOS-$releasever - Extras
baseurl=http://mirrors.163.com/centos/4/extras/i386/
gpgcheck=1

[centosplus]
name=CentOS-$releasever - Plus
baseurl=http://mirrors.163.com/centos/4/centosplus/i386/
gpgcheck=1
enabled=0
rpm --import http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-4

运行update:
yum update

升级:
yum upgrade

安装其它软件,例如:
yum install mplayer