HPE GreenLake Administration
- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - Linux
- >
- Re: Wht is the difference between /lib & /lib/tls ...
Operating System - Linux
1829102
Members
2371
Online
109986
Solutions
Forums
Categories
Company
Local Language
back
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
back
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Blogs
Information
Community
Resources
Community Language
Language
Forums
Blogs
Go to solution
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-15-2004 03:43 PM
11-15-2004 03:43 PM
Hi ,
I am new to Linux. I have one question regarding the libraries.In Redhat Enterprise Server 3.0 there are two directories for the libraries one is /lib & the other is /lib/tls.When I try to use libc by default it takes me to /lib/tls.libc-x.xx.x file but I want to use /lib/libc-x.xx.x file.. I did'nt get it wht is this /lib/tls folder for & why are there two instance of the same file in these two locations plus size wise also they differ..
I am new to Linux. I have one question regarding the libraries.In Redhat Enterprise Server 3.0 there are two directories for the libraries one is /lib & the other is /lib/tls.When I try to use libc by default it takes me to /lib/tls.libc-x.xx.x file but I want to use /lib/libc-x.xx.x file.. I did'nt get it wht is this /lib/tls folder for & why are there two instance of the same file in these two locations plus size wise also they differ..
Solved! Go to Solution.
1 REPLY 1
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-16-2004 11:57 AM
11-16-2004 11:57 AM
Solution
Libraries in /lib/tls are new NPTL POSIX thread libraries. By default, programs are linked with libc in /lib/tls. To change this you have to set LD_ASSUME_KERNEL variable.
$ export LD_ASSUME_KERNEL=2.2.5
$ ldd /bin/ls | grep libc
libc.so.6 => /lib/libc.so.6 (0xf6eb6000)
To find out version number to use with LD_ASSUME_KERNEL you can run eu-readelf on libc library (eu-readelf is in elfutils package).
$ /usr/bin/eu-readelf -n /lib/libc-2.3.3.so
Note segment of 32 bytes at offset 0x154:
Owner Data size Type
GNU 16 VERSION
OS: Linux, ABI: 2.2.5
$ export LD_ASSUME_KERNEL=2.2.5
$ ldd /bin/ls | grep libc
libc.so.6 => /lib/libc.so.6 (0xf6eb6000)
To find out version number to use with LD_ASSUME_KERNEL you can run eu-readelf on libc library (eu-readelf is in elfutils package).
$ /usr/bin/eu-readelf -n /lib/libc-2.3.3.so
Note segment of 32 bytes at offset 0x154:
Owner Data size Type
GNU 16 VERSION
OS: Linux, ABI: 2.2.5
The opinions expressed above are the personal opinions of the authors, not of Hewlett Packard Enterprise. By using this site, you accept the Terms of Use and Rules of Participation.
Company
Events and news
Customer resources
© Copyright 2025 Hewlett Packard Enterprise Development LP