1.进入目录
[root@localhost ~]# mount -r /dev/cdrom /mnt [root@localhost ~]# cd /etc/yum.repo.d [root@localhost ~]# rm -rf *
2.安装服务
[root@localhost ~]# vi lewis.repo
3.进入目录后编写以下内容
[root@localhost ~]# [msf] ---此名称可以随便改 [root@localhost ~]# name=msf [root@localhost ~]# baseurl=file:///mnt/AppStream [root@localhost ~]# enabled=1 [root@localhost ~]# gpgcheck=0 [root@localhost ~]# [root@localhost ~]# [msf1] [root@localhost ~]# name=msf1 [root@localhost ~]# baseurl=file:///mnt/BaseOS [root@localhost ~]# enabled=1 [root@localhost ~]# gpgcheck=0 wq 退出
4.测试
[root@localhost ~]# lsblk ----查看挂载位置 [root@localhost ~]# cat lewis.repo ----查看编写的内容是否有错误



