centos linux 6.5 yum 从本地光盘安装system-config-kickstart

 通过命令 yum install system-config-kickstart-2.8.6.5-1.el6.noarch.rpm 时, 发现无法连接互联网,而采用rpm安装时又发现存在依赖关系非常复杂,只能采用从本地进行安装。

1、在centos系统里插入光盘

2、修改CentOS-Media.repo 文件

[root@node0 mnt]# vi /etc/yum.repos.d/CentOS-Media.repo 
# CentOS-Media.repo
#
#  This repo can be used with mounted DVD media, verify the mount point for
#  CentOS-6.  You can use this repo and yum to install items directly off the
#  DVD ISO that we release.
#
# To use this repo, put in your DVD and use it with the other repos too:
#  yum --enablerepo=c6-media [command]
#
# or for ONLY the media repo, do this:
#
#  yum --disablerepo=\* --enablerepo=c6-media [command]

[c6-media]
name=CentOS-$releasever - Media
baseurl=file:///media/CentOS/
        file:///media/cdrom/
        file:///media/cdrecorder/
        file:///mnt/forYum
gpgcheck=1
enabled=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-6


说明:   “file:///mnt/forYum这一行是添加上去的。

3、将光盘里的所有内容复制到forYum下    

    cp  -rf  /mnt/cdrom   /mnt/forYum

4、进入/mnt/forYum/Packages目录下(非常关键,否则会无法安装),root用户执行:

  [root@node0]# yum --disablerepo=* --enablerepo=c6-media install system-config-kickstart-2.8.6.5-1.el6.noarch.rpm

说明:如果不在此目录执行,会出现无法安装的情况。
Loaded plugins: fastestmirror, refresh-packagekit, security
Loading mirror speeds from cached hostfile
 * c6-media: 
Setting up Install Process
No package system-config-kickstart-2.8.6.5-1.el6.noarch.rpm available

 

参考:

http://blog.csdn.net/silent1/article/details/7637272

http://blog.chinaunix.net/uid-16974460-id-3080622.html

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值