CentOS 7 更换yum 源
2020-12-15 本文已影响0人
6309b0eed1c7
1、进入目录:/etc/yum.repos.d
2、备份:
mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.backup
3、更换新的源;
wget -O /etc/yum.repos.d/CentOS-Base.repo https://mirrors.aliyun.com/repo/Centos-7.repo
(注:阿里源:https://developer.aliyun.com/mirror/)
4、清空缓存
yum clean all
5、建立缓存
yum makecache