客户端配置
修改CentOS-Base.repo文件
vi /etc/yum.repos.d/ CentOS-Base.repo
enabled为1的baseurl都设置为服务端ip
baseurl= http://192.168.1.60/yum/CentOS
# CentOS-Base.repo
#
# The mirror system uses the connecting IP address of the client and the
# update status of each mirror to pick mirrors that are updated to and
# geographically close to the client. You should use this for CentOS updates
# unless you are manually picking other mirrors.
#
# If the mirrorlist= does not work for you, as a fall back you can try the
# remarked out baseurl= line instead.
#
#
[base]
name=CentOS-$releasever - Base
baseurl= http://192.168.1.60/yum/CentOS
gpgcheck=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-6
enabled=1
#additional packages that may be useful
[extras]
name=CentOS-$releasever - Extras
baseurl= http://192.168.1.60/yum/CentOS
gpgcheck=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-6
enabled=1
#additional packages that extend functionality of existing packages
[centosplus]
name=CentOS-$releasever - Plus
baseurl= http://192.168.1.60/yum/CentOS
gpgcheck=0
enabled=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-6