image.png
访问 http://192.168.0.105:9002/centos7/
image.png
在103上执行 安装 createrepo
install -y createrepo
image.png
createrepo /home/java/nginx1/html/repl/centos7/
image.png
至此服务端准备完yum 源服务就搭建好了
接下来在105上修改yum 源
cd /etc/yum.repos.d/
rename .repo .repo.bak ./*
image.png
vi rhel7.repo
[iso]
name=CentOS-7-x86_64-Everything-iso
baseurl=http://192.168.0.103:9002/centos7/
gpgcheck=1
enabled=1
gpgkey=http://192.168.0.103:9002/centos7/RPM-GPG-KEY-CentOS-7
添加nginx配置好的地址, enabled 设置为1,保存退出
yum clean all
yum makecache
yum repolist
image.png
到此处没有错误,就可以使用yum 安装软件了
yum search httpd
image.png
参考
https://blog.csdn.net/sinat_28521487/article/details/108750711
https://blog.csdn.net/C1041067258/article/details/83507125

评论列表