1、检查yum是否安装

rpm -qa |grep yum

2、利用CentOS的yum更新源来实现RHEL5的YUM功能

vi /etc/yum.repos.d/CentOS-Base.repo

[base]
name=CentOS-5-Base
#mirrorlist=http://mirrorlist.centos.org/?release=$releasever5&arch=$basearch&repo=os
#baseurl=http://mirror.centos.org/centos/$releasever/os/$basearch/
baseurl=http://ftp.sjtu.edu.cn/centos/5/os/$basearch/
gpgcheck=0
gpgkey=http://mirror.centos.org/centos/RPM-GPG-KEY-centos5
#released updates
[update]
name=CentOS-5-Updates
#mirrorlist=http://mirrorlist.centos.org/?release=4&arch=$basearch&repo=updates
baseurl=http://ftp.sjtu.edu.cn/centos/5/updates/$basearch/
gpgcheck=0
gpgkey=http://mirror.centos.org/centos/RPM-GPG-KEY-centos5
#packages used/produced in the build but not released
[addons]
name=CentOS-5-Addons
#mirrorlist=http://mirrorlist.centos.org/?release=4&arch=$basearch&repo=addons
baseurl=http://ftp.sjtu.edu.cn/centos/5/addons/$basearch/
gpgcheck=0
gpgkey=http://mirror.centos.org/centos/RPM-GPG-KEY-centos5
#additional packages that may be useful
[extras]
name=CentOS-5-Extras
#mirrorlist=http://mirrorlist.centos.org/?release=4&arch=$basearch&repo=extras
baseurl=http://ftp.sjtu.edu.cn/centos/5/extras/$basearch/
gpgcheck=0
gpgkey=http://mirror.centos.org/centos/RPM-GPG-KEY-centos5
#additional packages that extend functionality of existing packages
[centosplus]
name=CentOS-5-Plus
#mirrorlist=http://mirrorlist.centos.org/?release=4&arch=$basearch&repo=centosplus
baseurl=http://ftp.sjtu.edu.cn/centos/5/centosplus/$basearch/
gpgcheck=0
enabled=0
gpgkey=http://mirror.centos.org/centos/RPM-GPG-KEY-centos5
#contrib - packages by Centos Users
[contrib]
name=CentOS-5-Contrib
#mirrorlist=http://mirrorlist.centos.org/?release=4&arch=$basearch&repo=contrib
baseurl=http://ftp.sjtu.edu.cn/centos/5/contrib/$basearch/
gpgcheck=0
enabled=0
gpgkey=http://mirror.centos.org/centos/RPM-GPG-KEY-centos5
# vi dag.repo
[dag]
name=Dag RPM Repository for RHEL5
baseurl=http://ftp.riken.jp/Linux/dag/redhat/el5/en/$basearch/dag/
enabled=1
gpgcheck=0
gpgkey=http://ftp.riken.jp/Linux/dag/packages/RPM-GPG-KEY.dag.txt

3、导入key

rpm --import http://ftp.sjtu.edu.cn/centos/5/os/i386/RPM-GPG-KEY-CentOS-5

4、运行YUM,测试

RHEL5 yum更新源的更多相关文章

  1. RedHat 5 配置CentOS yum 更新源

    YUM是Redhat Linux在线安装更新及软件的工具,但是这是RHEL5的收费功能,如果没有购买Redhat的服务时不能使用RHEL5的更新源的,会提示注册. 由于CentOS是从Redhat演化 ...

  2. 配置CENTOS YUM更新源

    众所周知,Centos 有个很方便的软件安装工具  yum,但是默认安装完centos,系统里使用的是国外的centos更新源,这就造成了我们使用默认更新源安装或者更新软件时速度很慢的问题. 为了使用 ...

  3. CENTOS YUM更新源

    网络yum源和制作本地光盘yum源 配置CENTOS YUM更新源 yum安装rpm包安装后本地不清除的方法 sed -i 's#keepcache=0#keepcache=1#g' /etc/yum ...

  4. CentOS修改yum更新源

    1. 在修改前先备份该文件 cp /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.bak 2. 修改更新源配置文 ...

  5. 更改CentOS7的yum更新源

    1. 备份现有源: mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.bak 2.下载163源 wget h ...

  6. 几个国内速度最快的centos yum(更新源)

    转自:http://blog.itpub.net/15711267/viewspace-1068862/ 中国科技大学源 cd /etc/yum.repos.d mv CentOS-Base.repo ...

  7. [转帖]yum与apt-get的区别以及两者更新源(阿里/网易【163】)

    yum与apt-get的区别以及两者更新源(阿里/网易[163]) 版权声明:本文为博主原创文章,未经博主允许不得转载. https://blog.csdn.net/one_super_dreamer ...

  8. Linux修改系统以及pip更新源

    Linux修改系统以及pip更新源 时间:2015-08-01来源:csdn 作者:henulwj 修改系统更新源 你是否跟我一样在刚看时接触Linux时被系统更新源问题搞得晕头转向,不同的Linux ...

  9. RHEL5.6更新yum源

    RHEL5.6更新yum源记录,2017年2月20日 root用户切换目录至:/etc/yum.repos.d/ [root@localhost yum.repos.d]# pwd /etc/yum. ...

随机推荐

  1. python计算机视觉项目实践

    这是一个贝叶斯模型的计算机视觉小项目.希望大家通过这个简单的项目知道一般的计算机视觉项目是怎样操作的. 我先讲题目放在这里希望有兴趣的童鞋花一周的时间思考并用python实现.一周以后我来发布我的详细 ...

  2. spring boot @ConditionalOnxxx相关注解总结

    Spring boot @ConditionalOnxxx相关注解总结 下面来介绍如何使用@Condition public class TestCondition implements Condit ...

  3. webrtc 源码结构

    api WebRTC 接口层.包括 DataChannel, MediaStream, SDP相关的接口.各浏览器都是通过该接口层调用的 WebRTC. call 存放的是 WebRTC “呼叫(Ca ...

  4. kindle书摘-围城-相爱勿相伤

    https://github.com/starrtc/android-demo 围城(爱熄灭了灯,心围一座城.出版七十周年纪念版) (钱钟书) - 您在位置 #49-49的标注 | 添加于 2018年 ...

  5. Vue 获取自定义属性的值

    在jquery中,如果要获取 data-*** 的值可以通过 $('目标元素').data('属性名') 来获取. 在Vue中如何获取该值呢? 1.换个思路,作为参数传递. 如下代码: <but ...

  6. C#往SQLServer中插入大数据

    以前插入大数据的时候都是一条一条的插入,由于电脑配置不行,有一次17万条数据用了半个小时才插入完成,那个蛋疼啊! 前面听杨中科老师的课,发现一个很好的东西,25万条数据配置好的电脑几秒钟就完成了,那是 ...

  7. Python之排序

    1. 2维数组排序 (按照每行第一个数字从小到大进行排序) poses.sort(key=lambda x: x[0]) for ppp in poses: print ppp,','

  8. 损失函数Center Loss 代码解析

    center loss来自ECCV2016的一篇论文:A Discriminative Feature Learning Approach for Deep Face Recognition. 论文链 ...

  9. python 进行后端分页详细代码

    后端分页 两个接口 思路: 1. 先得到最大页和最小页数(1, 20) --> 传递给前端, 这样前端就可以知道有多少个页数 2. 通过传递页数得到当前页对应数据库的最大值和最小值 3. 通过s ...

  10. 【吉比特】G-bits2018校园春季招聘技术类岗位笔试经验

    笔试公司:厦门吉比特网络技术股份有限公司 笔试岗位:游戏研发工程师 笔试时间:2018年3月30日19:00-20:30 笔试形式:牛客网在线做题 笔试回忆: 笔试总共时长1小时半,共52道题.其中选 ...