配置本地Yum仓库
[root@localhost test]# lsaa.txt bb.txt rhel-6.4-x86_64.iso test.sh[root@localhost test]# mount -o loop rhel-6.4-x86_64.iso /media/ //系统介质挂载到/media/[root@localhost yum.repos.d]# cd /etc/yum.repos.d/ | lsrhel-source.repo[root@localhost yum.repos.d]# cp rhel-source.repo rhel-source.repo.bak[root@localhost yum.repos.d]# vim rhel-source.repo[root@localhost yum.repos.d]# cat rhel-source.repo[rhel-source] //[rhel-source]与下面的[rhel-source-beta]改一个就好,这是两个源name=Red Hat Enterprise Linux $releasever - $basearch - Sourcebaseurl=ftp://ftp.redhat.com/pub/redhat/linux/enterprise/$releasever/en/os/SRPMS/enabled=0gpgcheck=1gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release[rhel-source-beta]name=Red Hat Enterprise Linux $releasever Beta - $basearch - Sourcebaseurl=file:///media/enabled=1 //是否启用,1为启用,0为不启用gpgcheck=1 //是否校验gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-beta,file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release//配置文件完成,yum配置结束,下面安装一个软件测试是否成功[root@localhost yum.repos.d]# [root@localhost yum.repos.d]# yum install gcc //测试安装Loaded plugins: product-id,refresh-packagekit,security,subscription-managerThis system is not registered to Red Hat Subscription Management. You can use subscription-manager to register.rhel-source-beta | 3.9 kB 00:00 ... rhel-source-beta/primary_db | 3.1 MB 00:00 ... .............................//省领略
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。