centos7修改yum下载源为阿里源

在国内很多yum源不好用,所以改成国内的源很有必要

首先,切换到yum源目录

cd /etc/yum.repos.d

备份一下

sudo mv CentOS-Base.repo CentOS-Base.repo.backup

下载阿里的源

sudo wget -O CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo

清理缓存

 

yum clean all

重新生成缓存

yum makecache

posted @ 2017-09-11 09:05  菲菲菲菲菲常新的新手  阅读(258)  评论(0)    收藏  举报