一、备份当前源
1 | cd /etc/yum.repos.d/ |
二、使用wget下载阿里yum源repo文件
1 | wget http://mirrors.aliyun.com/repo/Centos-7.repo |
三、清理旧包
1 | yum clean all |
四、把下载下来阿里云repo文件设置成为默认源
1 | mv Centos-7.repo CentOS-Base.repo |
五、生成阿里云yum源缓存并更新yum源
1 | yum makecache |
一、备份当前源
1 | cd /etc/yum.repos.d/ |
二、使用wget下载阿里yum源repo文件
1 | wget http://mirrors.aliyun.com/repo/Centos-7.repo |
三、清理旧包
1 | yum clean all |
四、把下载下来阿里云repo文件设置成为默认源
1 | mv Centos-7.repo CentOS-Base.repo |
五、生成阿里云yum源缓存并更新yum源
1 | yum makecache |