centos7 yum下载慢不断换mirror的优化

参考: https://zhuanlan.zhihu.com/p/78471090

清除缓存 

yum clean all

元数据建立
 yum makecache

更新
 yum update


cd /etc/yum.repos.d/


备份yum
 mv CentOS-Base.repo CentOS-Base.repo.backup


下载新的centos7的 CentOS-Base.repo
 wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo  

再创建缓存

 yum makecache

 

posted @ 2020-02-13 15:33  zsls-lang  阅读(1170)  评论(0编辑  收藏  举报