Centos 8 更改为阿里云源 Alex

1、备份原来的源

1 cd /etc/yum.repos.d
2 cp CentOS-Linux-Base.repo CentOS-Base.repo.bak

2. 下载对应版本的repo文件

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

3、清除旧的yum缓存并生成新的yum缓存

1 yum clean all
2 yum makecache

 

原文地址:https://www.cnblogs.com/alexlv/p/14754841.html