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

as4 通过yum自动升级实现

时间:2016-06-29 18:42:15      阅读:160      评论:0      收藏:0      [点我收藏+]

标签:

第一种方法:

yum源来自chinalinuxpub.com,用的是centos包,
下载地址: http://www.chinalinuxpub.com/yum.tgz
安装:
tar zxvf yum.tgz
cd yum
rpm -ivh *.rpm

rm -rf /etc/yum.repos.d/CentOS-Base.repo
vi /etc/yum.repos.d/as4-update.repo
加入:
#released updates
[update]
name=Red Hat Enterprise AS release 4 Updates
baseurl=http://ftp.chinalinuxpub.com/redhat/enterprise/updates/4AS/
gpgcheck=1
gpgkey=http://ftp.chinalinuxpub.com/redhat/enterprise/RPM-GPG-KEY-linuxpub

vi /etc/yum.repos.d/as4-base.repo
加入:
#released base
[base]
name=Red Hat Enterprise AS release 4 Updates
baseurl=http://ftp.chinalinuxpub.com/redhat/enterprise/os/i***/RedHat/
gpgcheck=1
gpgkey=http://ftp.chinalinuxpub.com/redhat/enterprise/RPM-GPG-KEY-linuxpub

然后就可以正常使用yum了.

说道这里,大家知道选一个好的云服务器的重要性。
注册地址:https://www.pppcloud.cn/index.html?referral_code=MTQwMDM0MA==A8X5

技术分享

第二种方法:利用CentOS 的yum库升级RHEL AS4
1.下载并安装yum-2.4.0-1.centos4.noarch.rpm文件,下载地址为:
ftp://ftp.pbone.net/mirror/ftp.centos.org/4.2/os/alpha/CentOS/RPMS/yum-2.4.0-1.centos4.noarch.rpm

2.修改或建立/etc/yum.repos.d/CentOS-Base.repo为如下内容:
[base]
name=CentOS-$releasever – Base
baseurl=http://ftp.riken.jp/Linux/caos/centos/4.0/os/$basearch/
gpgcheck=1

#released updates
[update]
name=CentOS-$releasever – Updates
baseurl=http://ftp.riken.jp/Linux/caos/centos/4.0/updates/$basearch/
gpgcheck=1

#packages used/produced in the build but not released
[addons]
name=CentOS-$releasever – Addons
baseurl=http://ftp.riken.jp/Linux/caos/centos/4.0/addons/$basearch/
gpgcheck=1

#additional packages that may be useful
[extras]
name=CentOS-$releasever – Extras
baseurl=http://ftp.riken.jp/Linux/caos/centos/4.0/extras/$basearch/
gpgcheck=1

3.修改或建立/etc/yum.repos.d/dag.repo为如下内容:
[dag]
name=Dag RPM Repository for RHEL4
baseurl=http://ftp.riken.jp/Linux/dag/redhat/el4/en/$basearch/dag/
enabled=1
gpgcheck=1
gpgkey=http://ftp.riken.jp/Linux/dag/packages/RPM-GPG-KEY.dag.txt

4.运行update:
yum update

5.升级:
yum upgrade

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

as4 通过yum自动升级实现

标签:

原文地址:http://www.cnblogs.com/qq3391826735/p/5627589.html

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