CentOS 更换yum源

以网易的163源为例

http://mirrors.163.com/

CentOS 更换yum源_第1张图片CentOS 更换yum源_第2张图片

cd /etc/yum.repos.d/
mv CentOS-Base.repo CentOS-Base.repo.backup
wget http://mirrors.163.com/.help/CentOS7-Base-163.repo
mv CentOS7-Base-163.repo CentOS-Base.repo
yum clean all
yum makecache
yum update

参考:

https://blog.csdn.net/shengshengshiwo/article/details/84191515

https://cloud.tencent.com/developer/article/1171376

你可能感兴趣的:(CentOS)