• 当yum安装出现Error: Package: glibc-headers .....时


    环境

    CentOS Linux release 7.4.1708 (Core)
     

    当使用yum源安装时,出现以下报错

    Error: Package: glibc-headers-2.17-196.el7_4.2.x86_64 (ultra-centos-7.4-updates)
               Requires: glibc = 2.17-196.el7_4.2
               Installed: glibc-2.17-222.el7.x86_64 (installed)
                   glibc = 2.17-222.el7
               Available: glibc-2.17-196.el7.x86_64 (ultra-centos-7.4-base)
                   glibc = 2.17-196.el7
               Available: glibc-2.17-196.el7_4.2.x86_64 (ultra-centos-7.4-updates)
                   glibc = 2.17-196.el7_4.2
    Error: Package: gcc-4.8.5-16.el7_4.2.x86_64 (ultra-centos-7.4-updates)
               Requires: libgomp = 4.8.5-16.el7_4.2
               Installed: libgomp-4.8.5-28.el7_5.1.x86_64 (installed)
                   libgomp = 4.8.2-16.el7_5
                   libgomp = 4.8.5-28.el7_5.1
               Available: libgomp-4.8.5-16.el7.x86_64 (ultra-centos-7.4-base)
                   libgomp = 4.8.5-16.el7
                   libgomp = 4.8.2-16.el7
               Available: libgomp-4.8.5-16.el7_4.1.x86_64 (ultra-centos-7.4-updates)
                   libgomp = 4.8.5-16.el7_4.1
                   libgomp = 4.8.2-16.el7_4
               Available: libgomp-4.8.5-16.el7_4.2.x86_64 (ultra-centos-7.4-updates)
                   libgomp = 4.8.5-16.el7_4.2
                   libgomp = 4.8.2-16.el7_4
    Error: Package: glibc-devel-2.17-196.el7_4.2.x86_64 (ultra-centos-7.4-updates)
               Requires: glibc = 2.17-196.el7_4.2
               Installed: glibc-2.17-222.el7.x86_64 (installed)
                   glibc = 2.17-222.el7
               Available: glibc-2.17-196.el7.x86_64 (ultra-centos-7.4-base)
                   glibc = 2.17-196.el7
               Available: glibc-2.17-196.el7_4.2.x86_64 (ultra-centos-7.4-updates)
                   glibc = 2.17-196.el7_4.2
     You could try using --skip-broken to work around the problem
     You could try running: rpm -Va --nofiles --nodigest
     

    解决办法

    wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo
    sed -i  's/$releasever/7/g' /etc/yum.repos.d/CentOS-Base.repo
    yum repolist 
  • 相关阅读:
    BZOJ 1021 循环的债务
    BZOJ 1019 汉诺塔
    BZOJ 1018 堵塞的交通
    BZOJ 1017 魔兽地图
    BZOJ 1016 最小生成树计数
    Luogu 3008 [USACO11JAN]道路和飞机Roads and Planes
    Luogu 3625 [APIO2009]采油区域
    Luogu 4139 上帝与集合的正确用法
    Luogu 3629 [APIO2010]巡逻
    Luogu 3626 [APIO2009]会议中心
  • 原文地址:https://www.cnblogs.com/lemon-le/p/10538023.html
Copyright © 2020-2023  润新知