Skip to content

Instantly share code, notes, and snippets.

@harv
Last active March 1, 2024 08:42
Show Gist options
  • Save harv/f86690fcad94f655906ee9e37c85b174 to your computer and use it in GitHub Desktop.
Save harv/f86690fcad94f655906ee9e37c85b174 to your computer and use it in GitHub Desktop.
update glibc to 2.17 for CentOS 6
#! /bin/sh
# update glibc to 2.17 for CentOS 6
wget http://copr-be.cloud.fedoraproject.org/results/mosquito/myrepo-el6/epel-6-x86_64/glibc-2.17-55.fc20/glibc-2.17-55.el6.x86_64.rpm
wget http://copr-be.cloud.fedoraproject.org/results/mosquito/myrepo-el6/epel-6-x86_64/glibc-2.17-55.fc20/glibc-common-2.17-55.el6.x86_64.rpm
wget http://copr-be.cloud.fedoraproject.org/results/mosquito/myrepo-el6/epel-6-x86_64/glibc-2.17-55.fc20/glibc-devel-2.17-55.el6.x86_64.rpm
wget http://copr-be.cloud.fedoraproject.org/results/mosquito/myrepo-el6/epel-6-x86_64/glibc-2.17-55.fc20/glibc-headers-2.17-55.el6.x86_64.rpm
sudo rpm -Uvh glibc-2.17-55.el6.x86_64.rpm \
glibc-common-2.17-55.el6.x86_64.rpm \
glibc-devel-2.17-55.el6.x86_64.rpm \
glibc-headers-2.17-55.el6.x86_64.rpm
@burakoznur
Copy link

burakoznur commented Nov 17, 2021 via email

@JEGANMANIC
Copy link

Figured it out!!
I'm new to rpm package commands and just need to pass "--force --nodeps" options to rpm command, update was successful.

root@bse [/usr/local/lib]# rpm -Uvh --force --nodeps libstdc++-4.8.5-44.el7.x86_64.rpm
warning: libstdc++-4.8.5-44.el7.x86_64.rpm: Header V3 RSA/SHA256 Signature, key ID f4a80eb5: NOKEY
Preparing... ########################################### [100%]
1:libstdc++ ########################################### [100%]
root@bse [/usr/local/lib]# strings /usr/lib64/libstdc++.so.6 | grep GLIBCXX
GLIBCXX_3.4
GLIBCXX_3.4.1
GLIBCXX_3.4.2
GLIBCXX_3.4.3
GLIBCXX_3.4.4
GLIBCXX_3.4.5
GLIBCXX_3.4.6
GLIBCXX_3.4.7
GLIBCXX_3.4.8
GLIBCXX_3.4.9
GLIBCXX_3.4.10
GLIBCXX_3.4.11
GLIBCXX_3.4.12
GLIBCXX_3.4.13
GLIBCXX_3.4.14
GLIBCXX_3.4.15
GLIBCXX_3.4.16
GLIBCXX_3.4.17
GLIBCXX_3.4.18
GLIBCXX_3.4.19
GLIBCXX_DEBUG_MESSAGE_LENGTH

@JEGANMANIC
Copy link

@hao - Thank you for posting this solution!! You saved lot of time!!

@axlroden
Copy link

axlroden commented Jan 10, 2022

WARNING

This will brick many things in your Centos 6 distro, and there is no clean way to go back without knowing all symlinks before you install these.
If you are trying to do something with python that complains about requiring glibc over 2.12, consider using pip version 19 (pip install pip==19), it will use the manylinux2010 (based on Centos 6) wheels and may have c binaries for your system.

If you are compiling c binaries that need glibc > 2.12 its better to install glibc in a seperate folder and use PATH (LD_LIBRARY_PATH=/opt/glibc-2.17/lib)to link to it instead

@JEGANMANIC
Copy link

Thanks for the suggestion! We built latest python 3.9 on CentOS 6 but it was giving error that unable to load libc.so.6, so had to configure LD_LIBRARY_PATH and works

@jhult
Copy link

jhult commented Jan 11, 2022

@Sahil148024
Copy link

Hello team,

kindly help me in getting EoS/EoL date for FOSS Glibc 2.17.0.

Regards,
Sahil

@nainajais777
Copy link

Screenshot-1

kindly help ..i am trying to install visual studio code in CentOS6

@axlroden
Copy link

axlroden commented Oct 13, 2022

kindly help ..i am trying to install visual studio code in CentOS6

You can't.

@nainajais777
Copy link

kindly help ..i am trying to install visual studio code in CentOS6

You can't.

But why...i am using CentOS [10].What is the solution?

@axlroden
Copy link

Upgrade OS.

@Zhang21
Copy link

Zhang21 commented Apr 23, 2023

rpm -Uvh --nodeps

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment