zoukankan      html  css  js  c++  java
  • YumRepo Error: All mirror URLs are not using ftp, http[s] or file.centos6 yum失败!

    具体在使用yum安装wget的时候,报了如下的错误

     原因:centos6的默认源在2012年-12月左右被官方搞掉了

    第一种方法:一键修复(一条一条执行即可):

    一般执行了前3条命令就好了

    sed -i "s|enabled=1|enabled=0|g" /etc/yum/pluginconf.d/fastestmirror.conf
    mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.backup
    curl -o /etc/yum.repos.d/CentOS-Base.repo https://www.xmpan.com/Centos-6-Vault-Aliyun.repo 
    yum clean all
    yum makecache

    第二种方法:手动修复教程:

    首先把fastestmirrors关了

    vi /etc/yum/pluginconf.d/fastestmirror.conf

     enable=0

    先把之前的repo挪到备份,然后下面两个二选一

    mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.bak

    替换为官方Vault源

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

    替换为阿里云Vault镜像

    curl -o /etc/yum.repos.d/CentOS-Base.repo https://www.xmpan.com/Centos-6-Vault-Aliyun.repo
  • 相关阅读:
    Struts2之Action基础与配置
    关于Struts2的类型转换详解
    Struts2自定义类型转换器
    MyEclipse 快捷键
    Struts2中的ActionContext
    struts2中的action访问web对象
    5.9每日一题题解
    5.8 每日一题题解
    5.7 每日一题题解
    5.6 每日一题题解
  • 原文地址:https://www.cnblogs.com/zouhong/p/14600512.html
Copyright © 2011-2022 走看看