5

How do I install glibc on a CentOS server?

I did:

yum install glibc-devel

But it tells me that the version glibc 2.15 is installed.

However i need to have the version 2.17.

Michael Hampton
  • 237,123
  • 42
  • 477
  • 940
Zenet
  • 878
  • 4
  • 10
  • 14

4 Answers4

6

You can find the official glibc versions for CentOS on the CentOS mirror sites.

For example

Dominik
  • 2,198
  • 13
  • 9
6

If you are absolutely sure you need it, you have two choices:

  1. use a different distribution that has the version you need (perhaps in a VM on top of your CentOS)
  2. Compile everything manually (I'd install rpm-build and use make rpm, but this might
    a) break dependencies in the system, and
    b) be a pretty complicated task to do, since the new version of glibc will require a lot of other prerequisites)
Scott Pack
  • 14,717
  • 10
  • 51
  • 83
dyasny
  • 18,482
  • 6
  • 48
  • 63
4

Well, that means that CentOS only has version 2.15 in its repositories. You could try to use yum --enablerepo=updates-testing --enablerepo=testing install glibc-devel but be aware, that an incompatible glibc may lead to problems with installed programs.

DaDaDom
  • 532
  • 6
  • 16
-5

To install glib on CentOS/RedHat/Fedora:

Login as root user via command prompt/shell

yum install glib*
  • This would install a lot of things which aren't necessary or wanted. – Michael Hampton Jun 12 '14 at 03:00
  • Do it once and never mind about it again. That's what I think. When you are going to build source code, you may need it one time or another, so why not install it all first? then focus on other things rather than lacking of libraries. – Linh Lino Jun 12 '14 at 03:05
  • 3
    Don't ever go into system administration, then. That's exactly the opposite of best practice, which is to install nothing that isn't necessary. – Michael Hampton Jun 12 '14 at 03:07
  • don't tell people what they can do ok? so I guess you never install anything rather than your needs? when try to build a source code and it said that you dont have a library which u never seen it in ur life and no idea what it is, wouldn't you try anything the internet says and hope that it will fix your problem? – Linh Lino Jun 12 '14 at 03:17
  • 2
    @LinhLino You realize that this question is **4 YEARS** old, and your solution simply installs all of the current glib packages in the repo rather than the specific version that at the time of the question was bleeding edge. – Jacob Jun 12 '14 at 03:23
  • No, I absolutely would not try anything I saw on the internet. Rather, I would try to understand what the problem is, what is missing, and how to properly correct it. – Falcon Momot Jun 12 '14 at 03:25
  • at least it produced upvotes for the questions that aren't pure idiocy. – Magellan Jun 12 '14 at 03:37
  • @Falcon Momot oh really? tell me how many libraries you know in the system? – Linh Lino Jun 12 '14 at 03:39
  • I can't tell why you think identifying and installing libraries is such a desperate and complex process. It's completely trivial and doesn't require you to have encyclopaedic knowledge of them. Are you actually a system administrator? – Falcon Momot Jun 12 '14 at 03:43
  • Fine, everyone, keeps clicking minus my answer. I bet that I will be the person who has the most minus answer in ServerFault :D. NO problem and I am not gonna delete this. I believe that someone will understand what I tried to say. – Linh Lino Jun 12 '14 at 03:44
  • @Falcon I am really not otherwise pp would hate me more. I just dont believe that we can understand something that we even cant see from sourcecode. – Linh Lino Jun 12 '14 at 03:46
  • Most minused answer on ServerFault? [Nope. Not Even Close.](http://serverfault.com/questions/80924/what-are-the-five-built-in-groups-in-windows-server-2008) – tombull89 Jun 12 '14 at 16:52
  • 2
    `When you are going to build source code, you may need it one time or another, so why not install it all first?` Why not? Alright. Well, you asked... (1) Disk space (2) processor cycles (some things are services / daemons, so you install them once and you're paying forever) (3) your time (it takes a hell of a lot of time to install everything) (4) robustness (often, installing things requires removing other things, so good luck with the dependency nightmares you create) (5) security! More code on the system- especially more services with default passwords- means more attack vectors. – Parthian Shot Jul 31 '15 at 03:28
  • 2
    (6) Auditing! (related to security) Should what's happening right now be concerning? Is it indicative of a hack? If you install everything, who knows! You don't. If you don't know what should be happening, you can't tell when malware is on the system, which brings us to... (7) standards compliance! Installing everything is pretty much guaranteed to break whatever security compliance your company requires. (8) uptime; more applications means more code that might break your system- either due to exploitation or a simple bug. Also means that, when a server does fail, you'll take longer to – Parthian Shot Jul 31 '15 at 03:30
  • 1
    get back online, because you need to wait to install everything that GNU has ever written. – Parthian Shot Jul 31 '15 at 03:31
  • 1
    ...Are the first eight reasons that occurred to me. I thought I'd stop at eight. Eight isn't all the reasons, but it's definitely enough. – Parthian Shot Jul 31 '15 at 03:32