Sigar & glibc

Stefan Negrea snegrea at redhat.com
Tue Sep 11 15:07:44 UTC 2012



----- Original Message -----
> From: "John Sanda" <jsanda at redhat.com>
> To: rhq-devel at lists.fedorahosted.org
> Sent: Tuesday, September 11, 2012 9:20:00 AM
> Subject: Re: Sigar & glibc
> 
> Do we need to test with different versions of gclib (>= 2.5) ?

No, glibc is backwards compatible. Today it works more or less the same way. Sigar links against and older glibc version but it works on Linux distros with newer versions. The linking part is what is going to change.

Here is the ldd output for the Linux x86 native library distributed with RHQ 4.4:

	linux-gate.so.1 =>  (0x00f6d000)
	libc.so.6 => /lib/libc.so.6 (0x0034c000)
	/lib/ld-linux.so.2 (0x4261e000)

	Version information:
	./libsigar-x86-linux.so:
		libc.so.6 (GLIBC_2.1) => /lib/libc.so.6
		libc.so.6 (GLIBC_2.0) => /lib/libc.so.6


And here is the ldd output for the Linux x86 native library to be distributed with RHQ 4.5:
	linux-gate.so.1 =>  (0x00236000)
	libc.so.6 => /lib/libc.so.6 (0x003e0000)
	/lib/ld-linux.so.2 (0x4261e000)

	Version information:
	./libsigar-x86-linux.so:
		libc.so.6 (GLIBC_2.1.3) => /lib/libc.so.6
		libc.so.6 (GLIBC_2.3.4) => /lib/libc.so.6
		libc.so.6 (GLIBC_2.3) => /lib/libc.so.6
		libc.so.6 (GLIBC_2.1.2) => /lib/libc.so.6
		libc.so.6 (GLIBC_2.2) => /lib/libc.so.6
		libc.so.6 (GLIBC_2.1) => /lib/libc.so.6
		libc.so.6 (GLIBC_2.0) => /lib/libc.so.6

If I interpret this output correctly, the newer binary requires a minimum glibc version of 2.3.4 (even though it was built against glibc 2.5) while the old one links against 2.1. So with this change support would be dropped for all distros that use glibc versions prior to 2.3.4.


Maybe somebody with more experience can shed more light into this library linking ...



Thank you,
Stefan Negrea



> 
> On Sep 11, 2012, at 9:57 AM, Stefan Negrea <snegrea at redhat.com>
> wrote:
> 
> > Hello Everybody,
> > 
> > For RHQ 4.5, I plan on updating some Sigar native libraries with
> > new ones built from the same source as the current 1.6.5.132. The
> > native libraries will change only for x86 and x86_64 architectures
> > for Windows, Solaris (x84_64 only) and Linux. And again, these new
> > binary bits are built from the same source as the current
> > 1.6.5.132 version distributed with RHQ 4.4. I do not see any issue
> > with this update for Solaris and Windows.
> > 
> > However, Linux is a little different because of glibc library
> > linking. The version to be released with RHQ 4.5 is built against
> > glibc 2.5. Since glibc is backwards compatible, this update should
> > not impact any Linux deployments that use glibc 2.5 or newer
> > versions. Glibc 2.5 was released in September 2006, which is quite
> > a while back; the most recent glibc version is 2.16. From my
> > investigation, most Linux distros should be on glibc 2.7 or newer
> > versions.
> > 
> > 
> > Does anybody see any problems with regards to linking Linux Sigar
> > native libraries against glibc 2.5?
> > 
> > 
> > Thank you,
> > Stefan Negrea
> > 
> > Software Engineer
> > 
> > _______________________________________________
> > rhq-devel mailing list
> > rhq-devel at lists.fedorahosted.org
> > https://lists.fedorahosted.org/mailman/listinfo/rhq-devel
> 
> _______________________________________________
> rhq-devel mailing list
> rhq-devel at lists.fedorahosted.org
> https://lists.fedorahosted.org/mailman/listinfo/rhq-devel
> 


More information about the rhq-devel mailing list