Unix Technical Forum

Bad magic number for shared library: libdb2.so

This is a discussion on Bad magic number for shared library: libdb2.so within the DB2 forums, part of the Database Server Software category; --> Hi, I am trying to run my application (32-bit) on HP-UX 11.22i (64-bit) and am getting the above message ...


Go Back   Unix Technical Forum > Database Server Software > DB2

Register FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 02-27-2008, 06:52 AM
Vandana Sharma
 
Posts: n/a
Default Bad magic number for shared library: libdb2.so

Hi, I am trying to run my application (32-bit) on HP-UX 11.22i (64-bit)
and am getting the above message while dynamically loading libdb2.so
from my application. I am using dlopen as follows:

dlopen(libName, RTLD_NOW);

I have looked up notes from DB2 that say that as long as I link with
32-bit DB2 libs, the application should work. I have made sure I have
32-bit DB2 libs in the SHLIB_PATH and also made sure that my
application is built with +s ld flag.

Has anyone run into this or has any pointers about this vague error
message from dlopen?

Thanks!

-Vandana

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 02-27-2008, 06:53 AM
Kiran Nair
 
Posts: n/a
Default Re: Bad magic number for shared library: libdb2.so

Hi,
Did you rebind your application against db2 ?
Or
Is it a CLI or Embedded C program ?

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 02-27-2008, 06:53 AM
Vandana Sharma
 
Posts: n/a
Default Re: Bad magic number for shared library: libdb2.so


Hi, thanks for your response.

It's a embedded C program that utilizes some of DB2 CLI and API calls
to attach to instance, connect to database etc. Since dlopen is
failing, I don't know whether it's a dlopen implementation issue or
whether libdb2.so is built differently on 64-bit and that is causing
the problem. What do you think might be happening here?

Thanks,
-Vandana

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 08:35 AM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
www.UnixAdminTalk.com