由于非得使用4.7的版本,所以找了一大圈,终于发现了一个能用的源:
更新方法如下:
vi /etc/yum.repos.d/CentOS-Base.repo内容如下:
[base]
name=CentOS-$releasever - Base#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=os#baseurl=http://mirror.centos.org/centos/$releasever/addons/$basearch/baseurl=http://mirrors.usc.edu/pub/linux/distributions/centos/4.8/os/$basearch/gpgcheck=1#gpgkey=http://mirror.centos.org/centos/RPM-GPG-KEY-centos4gpgkey=http://mirrors.usc.edu/pub/linux/distributions/centos/RPM-GPG-KEY-centos4priority=1protect=1#released updates
[update]name=CentOS-$releasever - Updates#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=updatesbaseurl=http://mirrors.usc.edu/pub/linux/distributions/centos/4.8/updates/$basearch/gpgcheck=1gpgkey=http://mirrors.usc.edu/pub/linux/distributions/centos/RPM-GPG-KEY-centos4priority=1protect=1#packages used/produced in the build but not released
[addons]name=CentOS-$releasever - Addons#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=addonsbaseurl=http://mirrors.usc.edu/pub/linux/distributions/centos/4.8/addons/$basearch/gpgcheck=1gpgkey=http://mirrors.usc.edu/pub/linux/distributions/centos/RPM-GPG-KEY-centos4priority=1protect=1#additional packages that may be useful
[extras]name=CentOS-$releasever - Extras#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=extrasbaseurl=http://mirrors.usc.edu/pub/linux/distributions/centos/4.8/extras/$basearch/gpgcheck=1gpgkey=http://mirrors.usc.edu/pub/linux/distributions/centos/RPM-GPG-KEY-centos4priority=1protect=1#additional packages that extend functionality of existing packages
[centosplus]name=CentOS-$releasever - Plus#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=centosplusbaseurl=http://mirrors.usc.edu/pub/linux/distributions/centos/4.8/centosplus/$basearch/gpgcheck=1enabled=0gpgkey=http://mirrors.usc.edu/pub/linux/distributions/centos/RPM-GPG-KEY-centos4priority=2protect=1#contrib - packages by Centos Users
[contrib]name=CentOS-$releasever - Contrib#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=contribbaseurl=http://mirrors.usc.edu/pub/linux/distributions/centos/4.8/contrib/$basearch/gpgcheck=1enabled=0gpgkey=http://mirrors.usc.edu/pub/linux/distributions/centos/RPM-GPG-KEY-centos4priority=2protect=1
接下来,导入keyrpm --import yum upgrade[root@localhost yum.repos.d]# yum upgradebase 100% |=========================| 1.1 kB 00:00 primary.xml.gz 100% |=========================| 856 kB 00:07 base : ################################################## 2458/2458updates 100% |=========================| 951 B 00:00 primary.xml.gz 100% |=========================| 129 kB 00:02 updates : ################################################## 324/324addons 100% |=========================| 951 B 00:00 primary.xml.gz 100% |=========================| 157 B 00:00 extras 100% |=========================| 1.1 kB 00:00 primary.xml.gz 100% |=========================| 74 kB 00:02 extras : ################################################## 244/244yum update
OK,到此为止,大功告成!!!!!!!!