Centos 7停止维护后的,换源策略

centos7 已经停止维护了,现在yum在没有换源的情况下都用不了了。

这时候我们先换到aliyun的源,目前还可以用。

一、备份现有源文件:

sudo cp /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.backup
二、下载阿里云的源配置文件:
sudo wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo
没有安装wget的时候用
curl -o /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo
三、清除缓存并生成新的缓存:
sudo yum clean all
sudo yum makecache

转载请注明出处 AE博客|墨渊 » Centos 7停止维护后的,换源策略

发表评论

路人甲

网友评论(0)