- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - Linux
- >
- Re: Threaded local storage ?
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Forums
Discussions
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
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- 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
тАО08-24-2005 11:59 PM
тАО08-24-2005 11:59 PM
Hi,
One of our customers got a problem with an application, the error message (part of it) is below:
/usr/lib/dld.sl: Can't shl_load() a library containing Thread Local Storage: /u10/test/testcomn/util/jre/1.1.8/bin/../lib/PA_RISC/native_threads/libjava.sl
From an Oracle metalink document I found that it is a known problem, "HP-UX do not allow dynamic loading of shared librarys which uses threaded local storage".
As I understand, this behaviour is made intentionally by HP. Is HP-UX different from other Unix here ?
Is there anyone who know more about this ?
Solved! Go to Solution.
- Tags:
- TLS
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-25-2005 12:16 AM
тАО08-25-2005 12:16 AM
SolutionI read something similar in a past posted forum:
http://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=929331
I found this answer to this argument:
The problem is that any shared library that contains Thread Local Storage (TLS) cannot be used as a dependency of another shared library. There are at least two ways around this problem. First, you can link each incomplete executable against each of the dependent library that use TLS. Second, you can use the LD_PRELOAD environment variable to load the dependent shared libraries at startup. You can specify multiple shared libraries by separating each library name with a colon. You can specify the full path the the library, or leave the path off the library name to cause the loader to use the standard search path.
Check this link:
http://web.gat.com/comp/analysis/mdsplus/textfilebusy.html
Hope this could be a minimal help,
Rgds,
Alessandro
- Tags:
- LD_PRELOAD
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-25-2005 12:17 AM
тАО08-25-2005 12:17 AM
Re: Threaded local storage ?
SEP
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-25-2005 12:27 AM
тАО08-25-2005 12:27 AM
Re: Threaded local storage ?
from HP doc Part Number: B2355-90730
http://docs.hp.com/en/B2355-90730/B2355-90730.html
Use caution when building shared libraries with external library dependencies. Any library that contains Thread Local Storage (TLS) should not be used as a dependency. If a dependent library contains TLS, and it is loaded during program startup (that is, not linked against the executable), the dynamic loader fails to perform the operation
You can use the LD_PRELOAD environment variable to load a shared library that contains thread-local storage to avoid the following error when loading the library dynamically:
/usr/lib/dld.sl: Can't shl_load() a library containing Thread Local Storage: /usr/lib/libpthread.1
Regards
Jean-Luc
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-25-2005 12:31 AM
тАО08-25-2005 12:31 AM
Re: Threaded local storage ?
Normally, shared libraries are linked directly with a program. Sometimes programmers decide that instead of linking a library directly to a program, they load a library when it's needed (with shl_load()) and unload it when it's no longer needed (shl_unload()).
In this case, library that is shl_loaded is libjava.sl. libjava.sl is linked with libpthread and/or libcl. libpthread and libcl are libraries that contain TLS.
Check with ldd
$ ldd /u10/test/testcomn/util/jre/1.1.8/bin/../lib/PA_RISC/native_threads/libjava.sl
The solution is to use environment variable LD_PRELOAD to load libraries in question (libjava.sl). The effect of using LD_PRELOADing the library is almost the same as linking it directly to the program.
$ LD_PRELOAD=/u10/test/testcomn/util/jre/1.1.8/bin/../lib/PA_RISC/native_threads/libjava.sl
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-25-2005 12:58 AM
тАО08-25-2005 12:58 AM
Re: Threaded local storage ?
Steven,
Yes, it is an Oracle application server but I am not sure about the version (I have not been in contact with the customer before). The only thing I know is that it is not the latest version and the customer is very negative to upgrading.
To All,
After some consulting we have decided that the problem is not ours, It should be solved by the Application developer. Many thanks for the hint about "LD_PRELOAD" , I will forward it.