现状:Red Hat Enterprise Linux Server release 5.5上可以使用YUM,但是需要到红帽官方注册,需要花钱。不花钱的方法:在局域网一台机器上为Red Hat Enterprise Linux Server release 5.5搭建一个YUM源,然后供局域网中的其他机器使用。yum源搭建 的详细流程:1 在A机器(CentOS release 6.4 (Final)系统)安装JDK、Tomcat、createrepo createrepo安装命令:yum install -y createrepo*2 将Red Hat Enterprise Linux Server release 5.5 ISO文件上传到A机器上/home/commonsoft/,并挂载到os文件夹中 挂载命令:mount -t iso9660 -o loop rhel-server-5.5-x86_64-dvd.iso os3 在/home/commonsoft/apache-tomcat-7.0.42/webapps/下面创建两个文件夹 mkdir rehl rehl14 将os文件夹中的东西全部COPY到rehl rehl1 各一份,然后删除rehl中所有的.html文件,删除rehl/Server/repodata/*、rehl/ServerStrorage/repodata/*、rehl/Cluster/repodata/*、rehl/VT/repodata/*5 建立rpm文件间的关系 createrepo -s sha -g /home/commonsoft/apache-tomcat-7.0.42/webapps/rehl1/Server/repodata/comps-rhel5-server-core.xml /home/commonsoft/apache-tomcat-7.0.42/webapps/rehl/Server/
createrepo -s sha -g /home/commonsoft/apache-tomcat-7.0.42/webapps/rehl1/Cluster/repodata/comps-rhel5-cluster.xml /home/commonsoft/apache-tomcat-7.0.42/webapps/rehl/Cluster/
createrepo -s sha -g /home/commonsoft/apache-tomcat-7.0.42/webapps/rehl1/ClusterStorage/repodata/comps-rhel5-cluster-st.xml /home/commonsoft/apache-tomcat-7.0.42/webapps/rehl/ClusterStorage/
createrepo -s sha -g /home/commonsoft/apache-tomcat-7.0.42/webapps/rehl1/VT/repodata/comps-rhel5-vt.xml /home/commonsoft/apache-tomcat-7.0.42/webapps/rehl/VT/6 创建rehl-5p5.repo文件,文件内容如下:[rehl-server]
name = rehl-server
baseurl = http://archive.cloudera.com/rehl/Server
gpgkey = http://archive.cloudera.com/rehl/RPM-GPG-KEY-RedHat-release
gpgcheck = 1
[rehl-cluster]
name = rehl-cluster
baseurl = http://archive.cloudera.com/rehl/Cluster
gpgkey = http://archive.cloudera.com/rehl/RPM-GPG-KEY-redhat-release
gpgcheck = 1
[rehl-clusterStorage]
name = rehl-clusterStorage
baseurl = http://archive.cloudera.com/rehl/ClusterStorage
gpgkey = http://archive.cloudera.com/rehl/RPM-GPG-KEY-redhat-release
gpgcheck = 1
[rehl-vt]
name = rehl-vt
baseurl = http://archive.cloudera.com/rehl/VT
gpgkey = http://archive.cloudera.com/rehl/RPM-GPG-KEY-redhat-release
gpgcheck = 17 将rehl-5p5.repo上传到B机器(Red Hat Enterprise Linux Server release 5.5系统)/etc/yum.repos.d并把xxx.xxx.xxx.xxx archive.cloudera.com写入B的/etc/hosts(可以先将别的没法使用的源删除)8 在B上执行yum clean all9 在B上执行yum list available,结果列出很多rpm文件,成功。
推荐阅读:RedHat Linux 本地yum源的配置 http://www.linuxidc.com/Linux/2013-08/88217.htmRedHat 6.2 Linux修改yum源免费使用CentOS源 http://www.linuxidc.com/Linux/2013-07/87383.htm配置EPEL YUM源 http://www.linuxidc.com/Linux/2012-10/71850.htmRedhat 本地yum源配置 http://www.linuxidc.com/Linux/2012-11/75127.htmyum的配置文件说明 http://www.linuxidc.com/Linux/2013-04/83298.htmRedHat 6.1下安装yum(图文) http://www.linuxidc.com/Linux/2013-06/86535.htmYUM 安装及清理 http://www.linuxidc.com/Linux/2013-07/87163.htm更多RedHat相关信息见RedHat 专题页面 http://www.linuxidc.com/topicnews.aspx?tid=10prettyping.sh: ping 之美如何在Linux中显示和设置主机名相关资讯 YUM源
- CentOS安装Yum源优先级插件Yum (08月03日)
- 离线(本地)Yum源搭建 (02月12日)
- RHEL 6.5 x86_64 配置CentOS yum源 (10/11/2015 08:15:28)
| - CentOS搭建本地yum源服务器 (07月14日)
- RHEL 5 建立本地yum源 (12/10/2015 09:18:07)
- CentOS7安装第三方yum源EPEL (10/10/2015 13:55:12)
|
本文评论 查看全部评论 (0)