Centos – Yum doesn’t recognize installed dependency version

centoscentos7yum

I'm trying to install gcc-c++ on CentOS 7.6.1810. This is the error output:

Error: Package: glibc-2.17-260.el7.i686 (centos_7_x64_32)
   Requires: glibc-common = 2.17-260.el7
   Installed: glibc-common-2.17-260.el7_6.3.x86_64 (@updates)
       glibc-common = 2.17-260.el7_6.3
   (cut)
   Available: glibc-common-2.17-260.el7.x86_64 (centos_7_x64_32)
       glibc-common = 2.17-260.el7

It seems that yum doesn't recognize glibc-common-2.17-260.el7_6.3.x86_64 as the same as (or equivalent of) glibc-common-2.17-260.el7_6.3.x86_64. What can I do to tell it to honor this installed version, or how can I reinstall it from centos_7_x64_32 (obviously I can't remove glibc-common first).

FULL OUTPUT

Resolving Dependencies
--> Running transaction check
---> Package gcc-c++.x86_64 0:4.8.5-36.el7 will be installed
--> Processing Dependency: gcc = 4.8.5-36.el7 for package: gcc-c++-4.8.5-36.el7.x86_64
--> Processing Dependency: libstdc++-devel = 4.8.5-36.el7 for package: gcc-c++-4.8.5-36.el7.x86_64
--> Processing Dependency: libmpc.so.3()(64bit) for package: gcc-c++-4.8.5-36.el7.x86_64
--> Processing Dependency: libmpfr.so.4()(64bit) for package: gcc-c++-4.8.5-36.el7.x86_64
--> Running transaction check
---> Package gcc.x86_64 0:4.8.5-36.el7 will be installed
--> Processing Dependency: cpp = 4.8.5-36.el7 for package: gcc-4.8.5-36.el7.x86_64
--> Processing Dependency: glibc-devel >= 2.2.90-12 for package: gcc-4.8.5-36.el7.x86_64
---> Package libmpc.x86_64 0:1.0.1-3.el7 will be installed
---> Package libstdc++-devel.x86_64 0:4.8.5-36.el7 will be installed
---> Package mpfr.x86_64 0:3.1.1-4.el7 will be installed
--> Running transaction check
---> Package cpp.x86_64 0:4.8.5-36.el7 will be installed
---> Package glibc-devel.x86_64 0:2.17-260.el7 will be installed
--> Processing Dependency: glibc-headers = 2.17-260.el7 for package: glibc-devel-2.17-260.el7.x86_64
--> Processing Dependency: glibc = 2.17-260.el7 for package: glibc-devel-2.17-260.el7.x86_64
--> Processing Dependency: glibc-headers for package: glibc-devel-2.17-260.el7.x86_64
--> Running transaction check
---> Package glibc.i686 0:2.17-260.el7 will be installed
--> Processing Dependency: glibc-common = 2.17-260.el7 for package: glibc-2.17-260.el7.i686
--> Processing Dependency: libfreebl3.so for package: glibc-2.17-260.el7.i686
--> Processing Dependency: libfreebl3.so(NSSRAWHASH_3.12.3) for package: glibc-2.17-260.el7.i686
---> Package glibc-headers.x86_64 0:2.17-260.el7 will be installed
--> Processing Dependency: kernel-headers >= 2.2.1 for package: glibc-headers-2.17-260.el7.x86_64
--> Processing Dependency: kernel-headers for package: glibc-headers-2.17-260.el7.x86_64
--> Running transaction check
---> Package glibc.i686 0:2.17-260.el7 will be installed
--> Processing Dependency: glibc-common = 2.17-260.el7 for package: glibc-2.17-260.el7.i686
---> Package kernel-headers.x86_64 0:3.10.0-957.1.3.el7 will be installed
---> Package nss-softokn-freebl.i686 0:3.36.0-5.el7_5 will be installed
--> Finished Dependency Resolution
Error: Package: glibc-2.17-260.el7.i686 (centos_7_x64_32)
           Requires: glibc-common = 2.17-260.el7
           Installed: glibc-common-2.17-260.el7_6.3.x86_64 (@updates)
               glibc-common = 2.17-260.el7_6.3
           Available: glibc-common-2.17-78.el7.x86_64 (centos_7_x64_32)
               glibc-common = 2.17-78.el7
           Available: glibc-common-2.17-105.el7.x86_64 (centos_7_x64_32)
               glibc-common = 2.17-105.el7
           Available: glibc-common-2.17-106.el7_2.1.x86_64 (centos_7_x64_32)
               glibc-common = 2.17-106.el7_2.1
           Available: glibc-common-2.17-106.el7_2.4.x86_64 (centos_7_x64_32)
               glibc-common = 2.17-106.el7_2.4
           Available: glibc-common-2.17-106.el7_2.6.x86_64 (centos_7_x64_32)
               glibc-common = 2.17-106.el7_2.6
           Available: glibc-common-2.17-106.el7_2.8.x86_64 (centos_7_x64_32)
               glibc-common = 2.17-106.el7_2.8
           Available: glibc-common-2.17-157.el7.x86_64 (centos_7_x64_32)
               glibc-common = 2.17-157.el7
           Available: glibc-common-2.17-157.el7_3.1.x86_64 (centos_7_x64_32)
               glibc-common = 2.17-157.el7_3.1
           Available: glibc-common-2.17-157.el7_3.2.x86_64 (centos_7_x64_32)
               glibc-common = 2.17-157.el7_3.2
           Available: glibc-common-2.17-157.el7_3.4.x86_64 (centos_7_x64_32)
               glibc-common = 2.17-157.el7_3.4
           Available: glibc-common-2.17-157.el7_3.5.x86_64 (centos_7_x64_32)
               glibc-common = 2.17-157.el7_3.5
           Available: glibc-common-2.17-196.el7.x86_64 (centos_7_x64_32)
               glibc-common = 2.17-196.el7
           Available: glibc-common-2.17-196.el7_4.2.x86_64 (centos_7_x64_32)
               glibc-common = 2.17-196.el7_4.2
           Available: glibc-common-2.17-222.el7.x86_64 (centos_7_x64_32)
               glibc-common = 2.17-222.el7
           Available: glibc-common-2.17-260.el7.x86_64 (centos_7_x64_32)
               glibc-common = 2.17-260.el7
 You could try using --skip-broken to work around the problem
 You could try running: rpm -Va --nofiles --nodigest

Best Answer

Error: Package: glibc-2.17-260.el7.i686 (My emphasis)

you are trying to install the i686 variant not the x86_64 variant. You need to meet the i686 requirements or install the x86_64 package.