温馨提示×

温馨提示×

您好,登录后才能下订单哦!

密码登录×
登录注册×
其他方式登录
点击 登录注册 即表示同意《亿速云用户服务条款》

建立本地yum仓库及建立网络yum仓库

发布时间:2020-06-29 18:55:51 来源:网络 阅读:353 作者:符十三郎 栏目:移动开发

mkdir /iso             #为ISO文件建立一个存放目录

mv /home/kiosk/Desktop/rhel-server-7.0-x86_64-dvd.iso /iso   #得到iso并保证位置安全      

 mount /iso/rhel-server-7.0-x86_64-dvd.iso /westos/     #挂载iso到/westos

 vim /etc/yum.repos.d/yum.repo--->

 [test]

 name=local software

 baseurl=file:///westos

 gpgcheck=0

                                                    』

mv rhel-dvd.repo rhel-dvd.repo.bak

mv rht-extras.repo rht-extras.repo.bak       #更改yum文件

yum clean all

yum repolist     #更新yum

yum install httpd -y

systemctl start httpd

systemctl enable httpd         #安装http并设置开机启动

systemctl stop firewalld

systemctl disable firewalld         #停止防火墙并设置开机不启动

umount /westos/

mount /iso/rhel-server-7.0-x86_64-dvd.iso /var/www/html/rhel7.0/   #挂载iso在/var/www/html/rhel7.0

 vim /etc/yum.repos.d/yum.repo--->

 [test]

 name=local software

 baseurl=http://172.25.28.250.rhel7.0

 gpgcheck=0                          』      #更改yum文件,地址设为IP地址  


向AI问一下细节

免责声明:本站发布的内容(图片、视频和文字)以原创、转载和分享为主,文章观点不代表本网站立场,如果涉及侵权请联系站长邮箱:is@yisu.com进行举报,并提供相关证据,一经查实,将立刻删除涉嫌侵权内容。

AI