All mirror URLs are not using ftp, http[s] or file

今天要yum点东西到服务器上,然后本地centos6用yum下载包,就报了All mirror URLs are not using ftp, http[s] or file.一顿操作猛如虎,一看效果0.5。终于还是万能的度娘告诉我因为centos6的支持给官方停掉了......

这样:

据说还有这样:

那你就这样做:

1.sed -i "s|enabled=1|enabled=0|g" /etc/yum/pluginconf.d/fastestmirror.conf

2.mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.backup

3.curl -o /etc/yum.repos.d/CentOS-Base.repo https://www.xmpan.com/Centos-6-Vault-Aliyun.repo

4.yum clean all

5.yum makecache

然后你就会发现问题就解决了

 

 

 

https://zhuanlan.zhihu.com/p/338873211

posted on   lansedongqing  阅读(229)  评论(0编辑  收藏  举报

相关博文:
阅读排行:
· 使用C#创建一个MCP客户端
· 分享一个免费、快速、无限量使用的满血 DeepSeek R1 模型,支持深度思考和联网搜索!
· ollama系列1:轻松3步本地部署deepseek,普通电脑可用
· 基于 Docker 搭建 FRP 内网穿透开源项目(很简单哒)
· 按钮权限的设计及实现

导航

< 2025年3月 >
23 24 25 26 27 28 1
2 3 4 5 6 7 8
9 10 11 12 13 14 15
16 17 18 19 20 21 22
23 24 25 26 27 28 29
30 31 1 2 3 4 5

统计

点击右上角即可分享
微信分享提示