1.安装wget
yum install wget
2.备份原来的源
cd /etc/yum.repos.d
mv CentOS-Base.repo CentOS-Base.repo.bak
3.下载替换源
wget http://mirrors.163.com/.help/CentOS7-Base-163.repo
mv CentOS7-Base-163.repo /etc/yum.repos.d/CentOS-Base.repo
4.清理缓存
yum clean all
yum makecache
5.更新系统
yum update -y