Centos将yum源设置为阿里云的镜像源

第一步:备份原有镜像源

mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.bak 

第二步:下载阿里云的镜像源

wget -O /etc/yum.repo.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo
//如果是cento 6的系统就将文件名改为Centos-6.repo

第三步 :重新设置缓存

yum clean all
yum makecache
原文地址:https://www.cnblogs.com/hg-super-man/p/10780349.html