建自己的yum源

yum服务端配置
yum -y install createrepo http
mount /dev/cdrom /mnt
cp /mnt/CentOS/* /var/www/html/yum/centos
createrepo /var/www/html/yum/centos
service httpd start
 
 
yum客户端配置
vi /etc/yum.repos.d/test.repo
[test]
name=test
baseurl=http://192.168.65.128/yum/centos/
enabled=1
gpgcheck=0
 
 
如果只使用这一个源,请把 /etc
/yum.repos.d 目录下别的文件删除,或者编辑其他文件,修改 enabled 参数为 0
这样yum服务器就配置好了

你可能感兴趣的:(yum服务器)