cd /etc/yum.repos.d/
rm CentOS-Base.repo
注意centos版本:
wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo
yum makecache
这是一个漫长的过程:
yum -y update
其中当然有想让你吟诗的时刻:
如果实在不行就换个镜像:
wget http://mirrors.163.com/.help/CentOS7-Base-163.repo
最终成功画面:
参考:
https://blog.csdn.net/inslow/article/details/54177191