`
leongfans
  • 浏览: 85453 次
  • 性别: Icon_minigender_1
  • 来自: 北京
社区版块
存档分类
最新评论

redhat yum from iso

阅读更多
Today I picked up Redhat again for the RHCE exam is coming soon.

After installing the basic system, meet problem, I need to do some DNS practice. But I don't like install the rpm package from DVD, I just want to yum it from the ISO source. So in order to make a good practice environment. I did the following steps:

1. mount the ISO file first and make it startup by system every time.

[root@redhat ~]# mkdir /mnt/win   # I want to mount windows partition to win folder

[root@redhat ~]# mkdir /mnt/iso   # I want to mount RHEL5 ISO to iso folder

[root@redhat ~]# chmode -R 777 /mnt/win /mnt/iso  # make sure there's enough privilage to access these two folders

[root@redhat ~]# fdisk -l   # Display all the partition

From the /etc/fstab, add this line:

/dev/hda1               /mnt/win                ntfs    umask=000       0 0  # This means to mount the NTFS partition when system startup

in /etc/rc.d/rc.local, add this line:

mount -o loop /mnt/win/ISO/rhel-5-server-i386-dvd.iso /mnt/iso  # This means to mount ISO file to /mnt/iso folder when system startup

[root@redhat ~]# mount -a

[root@redhat ~]# /etc/rc.local  # These two lines means to mount NTFS partition to /mnt/win first, then mount ISO file to /mnt/iso



2. Edit the repo file to make iso as yum source.

[root@redhat ~]# cd /etc/yum.repos.d

[root@redhat ~]# cp rhel-debuginfo.repo rhel-debuginfo.repo.bak  # Backup the default repo file

[root@redhat ~]# vim rhel-debuginfo.repo

edit the repo file like this:

[Server]
name=Red Hat Enterprise Linux ISO image
baseurl=file:///mnt/iso/Server/
enabled=1
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release

[VT]
name=VT
baseurl=file:///mnt/iso/VT/
enabled=1
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release

Please pay attention to the path. After finish the repo file. you can use yum, but first you must check the update

[root@redhat ~]# yum check-update  # If you find there are several 100% and no error, then everything will be fine!

[zz]http://zhouxuesong1980.blog.163.com/blog/static/76945154200932821525820/
分享到:
评论

相关推荐

    redhat5可用的yum文件

    redhat5可用的yum文件.及配置路径

    redhat yum依赖包

    redhat6 版本yum安装所需要的依赖包,解决yum安装过程的问题

    redhat yum

    linux的在线更新包可使用 rpm -ivh yum-*.rpm安装 安装完之后比如你要安装GCC编译器:yum install gcc

    redhat linux 配置yum详解

    redhat linux 配置yum详解

    redhat7.9 + yum.repos.d

    redhat7.9 + yum.repos.d +CentOS7-Base-163.repo + Centos-7-aliyun.repo

    RedHat未注册yum不能用解决办法

    RedHat未注册yum不能用解决办法; 卸载redhat自带的yum组件 rpm -qa|grep yum|xargs rpm -e --nodeps 安装centos的yum包

    RedHat6.2 yum源配置

    RedHat6.2 yum源配置方法,亲试成功!

    linux redhat yum 上海交大的CentOS更新源

    linux redhat yum 上海交大的CentOS更新源

    linux redhat centos修改yum下载源.zip_redhat yum源

    linux redhat centos修改yum下载源.zip

    RedHat9下安装yum

    安装了gcc后,源码安装gettext,再源码安装yum即可,亲测成功

    redhat 自动安装 yum 脚本

    自动化安装redhat yum 工具,省去寻找开源镜像,修改配置文件等繁琐过程,直接自动安装。 使用前请先自己将系统自带yum卸载, 卸载命令: rpm -qa|grep yum|xargs rpm -e -–nodeps

    redhat 6.5 yum源

    redhat 6.5 yum源

    redhat 5 yum 源

    redhat 5 yum源配置文档

    Redhat6.5配置yum本地源

    Redhat6.5配置yum本地源

    redhat 7.3 yum源.rar

    Yum(全称为 Yellow dog Updater, Modified)是一个在Fedora和RedHat以及CentOS中的Shell前端软件包管理器。基于RPM包管理,能够从指定的服务器自动下载RPM包并且安装,可以自动处理依赖性关系,并且一次安装所有...

    redhat 安装 yum

    1.卸载yum: #rpm -qa|grep yum|xargs rpm -e --nodeps 2.安装以下几个包 yum-3.2.22-26.el5.centos.noarch.rpm yum-fastestmirror-1.1.16-14.el5.centos.1.noarch.rpm yum-metadata-parser-1.1.2-3.el5.centos....

    RedHat 5.4yum源修改

    将redhat linux下收费yum源改为centos免费Yum源 有上网找的yum源软件包下载地址,直接就可以用

    redhat重装yum

    这个压缩包里有4个文件用来重装redhat的yum,解决虚拟机安装redhatyum不能用的问题,4个文件分别为python-iniparse-0.3.1-2.1.el6.noarch,yum-3.2.29-40.el6.centos.noarch,yum-metadata-parser-1.1.2-16.el6.x86_...

    Redhat 6.9 yum源的替换

    Redhat6.9系统替换郁闷源的所有包以及163.repo都在文件夹里面,因为自己在网上找了好久都没有一个完整的包,经过几天的搜集验证,把自己的通过的包发出来,希望对一些人游泳

    redhat7.6更新yum

    我的博客“redhat7.6虚拟机,解决更新包依赖问题”中提到的几个安装包和文件,包括:yum-3.4.3-161.el7.centos.noarch.rpm、python-iniparse-0.4-9.el7.noarch.rpm、yum-metadata-parser-1.1.4-10.el7.x86_64.rpm、...

Global site tag (gtag.js) - Google Analytics