<<<第十三单元练习>>>
1.在server主机中配置yum仓库,并安装gcc编辑器
1)mkdir /iso
2)挂载镜像文件mount /home/kiosk/Desktop/rhel-server-7.2-x86_64-dvd.iso /var/www/html/rhel7.2
3)配置本机yum源指向vim /etc/yum.repos.d/yum.repo
[SERVER]
name=rhel7.2
baseurl=http://172.25.254.62/rhel7.2
gpgcheck=0
4)安装共享服务
yum install httpd -y
systemctl stop firewlsh-plugin-11.2.202.451-release.x86_64.rpmld
systemctl disable firewalld
systemctl start httpd
systemctl enable httpd
5)建立共享目录,并挂在镜像文件到共享目录上
mkdir /var/www/html/rhel7.2
umount /mnt
mount rhel-server-7.2-x86_64-dvd.iso /var/www/html/rhel7.2
6)修改本机yum源指向
[server]
name=rhel7.2
baseurl=file:///var/www/html/rhel7.2
gpgcheck=0
7)开机自动挂在iso
vim /etc/rc.d/rc.local
mount rhel-server-7.1-x86_64-dvd.iso /var/www/html/rhel7.1
chmod +x /etc/rc.d/rc.local
8)查询gcc
yum search gcc
9)安装gcc
yum install gcc
搭建本地yum源,开机自动挂载
最新推荐文章于 2024-07-08 19:36:14 发布