centos7 配置yum源

centos7 更换yum源为国内yum,比如aliyun

1、备份运来的yum配置文件

mv /etc/yum.repos.d /etc/yum.repos.d.bkp

mkdir /etc/yum.repos.d 

2、获取aliyun yum源配置文件

cd /etc/yum.repos.d 

wget http://mirrors.aliyun.com/repo/Centos-7.repo 

3、yum源更新

yum clean all

yum makecache

猜你喜欢

转载自blog.csdn.net/Man_In_The_Night/article/details/86571640