- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Bad magic number for shared library: libclntsh.sl....
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
тАО01-05-2009 02:39 AM
тАО01-05-2009 02:39 AM
Bad magic number for shared library: libclntsh.sl.10.1
I have oracle 10g installed on HP Integrity rx 2620 server. OS is HP-UX 11i v2 FOE September 2006 (version B.11.23).
I have an application compiled on PA-RISC OS B.11.11 using aCC: HP ANSI C++ B3910B A.03.70 compiler.
Compiler options: +DA1.0 -AA -mt
My application makes use of oracle shared library: libclntsh.sl.10.1. It runs correctly on both PA-RISC v1 and v2. But on Itanium server i am getting Bad magic number for shared library: libclntsh.sl.10.1 error.
Also note that i have Aries installed on the Itanium server.
--
Thanks
Biradar
- Tags:
- ABI mismatch
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-05-2009 02:51 AM
тАО01-05-2009 02:51 AM
Re: Bad magic number for shared library: libclntsh.sl.10.1
It is illegal to use +DA1.0, the last OS that supported those machines was 10.10.
>I am getting Bad magic number for shared library libclntsh.sl.10.1 error.
Are you sure that SHLIB_PATH only contains PA32 shlibs? What does file(1) show for each?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-05-2009 03:56 AM
тАО01-05-2009 03:56 AM
Re: Bad magic number for shared library: libclntsh.sl.10.1
Thanks.
1. What compiler option i should using?
I want a single code base to run on both PA-RISC(v1 & v2)and Itanium.
2. SHLIB PATH is pointing to correct libs i guess.
$ echo $SHLIB_PATH
/opt/osmf/lib:/opt/oracle/app/oracle/product/10.2.0/lib
# pwd
/opt/oracle/app/oracle/product/10.2.0/lib32
# file libclntsh.so.10.1
libclntsh.so.10.1: ELF-32 shared object file - IA64
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-05-2009 09:52 AM
тАО01-05-2009 09:52 AM
Re: Bad magic number for shared library: libclntsh.sl.10.1
>I want a single code base to run on both PA-RISC(v1 & v2) and Integrity.
You can use +DSportable.
>2. SHLIB_PATH is pointing to correct libs I guess.
libclntsh.so.10.1: ELF-32 shared object file - IA64
These are the correct shlibs for an Integrity application. You need to find the PA shlibs, possibly copy them from your PA box, to a different location?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-05-2009 08:54 PM
тАО01-05-2009 08:54 PM
Re: Bad magic number for shared library: libclntsh.sl.10.1
Thanks once again.
> You can use +DSportable.
I have already tried with +DSportable option but without any success. I am still getting the same error.
> These are the correct shlibs for an Integrity application. You need to find the PA shlibs, possibly copy them from your PA box, to a different location?
You are right. My application needs to run on Integrity server itself. So i have Oracle 10g for Itanium installed on the box. The same application runs correctly on PA-RISC where Oracle 10g for PA-RISC is installed.
As i mentioned earlier i have Aries installed on the Itanium box. My application runs as a daemon. This is the error i am getting in nohup.out
/usr/lib/dld.sl: Bad magic number for shared library: /opt/osmf/lib/libclntsh.sl
.10.1
/usr/lib/dld.sl: Exec format error
[HP ARIES32]: Core file for 32 bit PA-RISC application
[HP ARIES32]: /opt/osmf/bin/osmfsemd saved to /var/opt/osmf/share/log/core.osm
fsemd.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-06-2009 02:22 AM
тАО01-06-2009 02:22 AM
Re: Bad magic number for shared library: libclntsh.sl.10.1
Naturally but faster. :-)
>I have Aries installed on the Integrity box.
No, you didn't do it. Aries comes with HP-UX on all Integrity servers.
>dld.sl: Bad magic number for shared library: /opt/osmf/lib/libclntsh.sl.10.1
You need to put a PA lib in that location. Or you need to use SHLIB_PATH to move your PA shlibs elsewhere.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-06-2009 02:37 AM
тАО01-06-2009 02:37 AM
Re: Bad magic number for shared library: libclntsh.sl.10.1
Thanks for the reply.
libclntsh.sl.10.1 is an Oracle library.
I have created a soft link to this library.
libclntsh.sl.10.1 -> /
opt/oracle/app/oracle/product/10.2.0/lib32/libclntsh.so.10.1
I have oracle 10g Itanium version installed on the box. Oracle 10g Itanium version unfortunately has no PA-RISC library. It has only IA libraries installed (both 32 / 64 bit)
$ file /opt/oracle/app/oracle/product/10.2.0/lib32/libclntsh.so.10.1
/opt/oracle/app/oracle/product/10.2.0/lib32/libclntsh.so.10.1: ELF-32 shared ob
ject file - IA64
$ file /opt/oracle/app/oracle/product/10.2.0/lib/libclntsh.so.10.1
/opt/oracle/app/oracle/product/10.2.0/lib/libclntsh.so.10.1: ELF-64 shared ob
ject file - IA64
Please let me know what should I be doing?
My program is complied on PA-RISC as i needs to be run on both PA-RISC / IA.
I can recompile my program on IA and make it run but i do not want to have 2 different binaries.
Also installing Oracle 10g PA-RISC on IA is another solution i can think of but i can do that as well.
So i have compatible oracle for each of the architectures but only one binary of mine.
How can i mke it run on both????
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-06-2009 02:46 AM
тАО01-06-2009 02:46 AM
Re: Bad magic number for shared library: libclntsh.sl.10.1
My program is compiled on PA-RISC and makes use of oracle library libclntsh.sl.10.1.
I have relative Oracle version installed on each of the boxes. viz. PA-RISC / IA
It runs correctly on both the versions of PA-RISC 1.1 and 2.0.
Now i want my same program compiled on PA-RISC to run correctly on IA box.
Unfortunately when i try to run it i get the following error.
/usr/lib/dld.sl: Bad magic number for shared library: /opt/osmf/lib/libclntsh.sl
.10.1
/usr/lib/dld.sl: Exec format error
[HP ARIES32]: Core file for 32 bit PA-RISC application
[HP ARIES32]: /opt/osmf/bin/osmfalert saved to /var/opt/osmf/share/log/core.os
mfalert.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-06-2009 02:47 AM
тАО01-06-2009 02:47 AM
Re: Bad magic number for shared library: libclntsh.sl.10.1
libclntsh.sl.10.1 -> /
opt/oracle/app/oracle/product/10.2.0/lib32/libclntsh.so.10.1
From /opt/osmf/lib?
You need to point to a PA shlib.
>Oracle 10g Itanium version unfortunately has no PA-RISC library. It has only IA libraries installed (both 32/64 bit)
Then your application isn't supported on Integrity.
>Please let me know what should I be doing?
>My program is complied on PA-RISC as I need to be run on both PA-RISC / IA.
You may need to have two versions. What you are doing is probably not supported by Oracle.
>I can recompile my program on IA and make it run but i do not want to have 2 different binaries.
You may not have a choice.
>Also installing Oracle 10g PA-RISC on IA is another solution i can think of but i can do that as well.
You can't do that.
>How can I make it run on both?
You must copy ALL of the load modules your application uses, including the PA oracle shlibs to your IPF box.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-06-2009 02:55 AM
тАО01-06-2009 02:55 AM
Re: Bad magic number for shared library: libclntsh.sl.10.1
You can use ldd(1) on your application on your PA box to get a list of all shlibs you use.
- Tags:
- ldd