Operating System - HP-UX
1833822 Members
2438 Online
110063 Solutions
New Discussion

library difference between compile env. and production env.

 
Dennis Handly
Acclaimed Contributor

Re: library difference between compile env. and production env.

>>How are you telling apache that you need both libaceauth.sl and mod_rsawa_apache.sl at the same time?

I need this answer.

>It could be difficult to do so

You could make one dependent on the other.

>Can you tell me how to download the latest dld?

PHSS_35381 but you seem to have it, B.11.60.

>Is "catch load" and "catch unload" gdb command?

Yes.

>After the changes, I have still the same problem. If you need "info shared", please let me know.

I'm assuming it is still failing the same way. We need to figure out what apache is doing. So you either need to use gdb, or you could attempt to use tusc to see what system calls are being made. That would catch the mmap(2) and munmap(2) for the shlibs.
tash S
Frequent Advisor

Re: library difference between compile env. and production env.


>>How are you telling apache that you need
>>both libaceauth.sl and
>>mod_rsawa_apache.sl at the same time?

> I need this answer.

I use libaceauth.sl using

shl_load(path, BIND_IMMEDIATE | BIND_NONFATAL, 0);

(I might think that we use some parameter instead of BIND_IMMEDIATE in order to delay getting the memory?)

But I do not use shl_load() for other mod_rsawa_apache.sl during initialization.

Here is the reference from Apache on HP-UX 11i.
http://developer.spikesource.com/errorbuddy/source/httpd-2.0.54/README.platforms

>>It could be difficult to do so
>You could make one dependent on the other.

Can you tell me more specific ?

>you could attempt to use tusc to see what
>system calls are being made.

This could be difficult, because the core is when apache starts, if the core is generated, we can not get the process number of http.

Can you tell me the usage of tusc in the above case.




tash S
Frequent Advisor

Re: library difference between compile env. and production env.

Deniss,

>How are you telling apache that you need >both libaceauth.sl and mod_rsawa_apache.sl >at the same time?

mod_rsawa_apache.sl is loaded by Apache.

The share library of mod_rsawa_apache.sl call libaceauth.sl uing shl_load().

In terms of libaceauth.sl , we use the following aCC command.

/opt/aCC/bin/aCC -b -o libaceauth.sl hp11/aaa_Apache.o -lstd_v2 -lCsup_v2 -Wl,-a,archive a1.a a2.a


a1.a a2.a is made by using ar command ( ar -r ) from C++ sources.

If you think the above is wrong, please let us know.



Dennis Handly
Acclaimed Contributor

Re: library difference between compile env. and production env.

>I use libaceauth.sl using
shl_load(path, BIND_IMMEDIATE|BIND_NONFATAL,0);

(I'm not sure if replacing this by BIND_DEFERRED would help?)

Can you take your initial stack trace and put the names libaceauth & mod_rsawa_apache on each frame you know? You can use ranges to make the list shorter.

It seems #1, 2, 4 are libaceauth.
Is #9 mod_rsawa_apache?
Attaching a new stack trace that matches that other info I asked would be helpful:
(gdb) set print max-symbolic-offset 1
(gdb) set redirect-file gdb.out
(gdb) set redirect on
(gdb) bt
(gdb) info shared
(gdb) set redirect off

>But I do not use shl_load()

And you don't use shl_unload/dlclose?

>Here is the reference from Apache on HP-UX 11i.

I just see something about "error buddy" and only mention about autoconf and libtool??

>>You could make one dependent on the other.

>Can you tell me more specific?

When you link mod_rsawa_apache, you just add -laceauth. Both libs will be there when apache loads mod_rsawa_apache.

>This could be difficult, because the core is when apache starts, if the core is generated, we can not get the process number of http.

>Can you tell me the usage of tusc in the above case.

You need to change your apache startup script to have:
tusc -pf -o tusc.out apache-command-and-parms

>mod_rsawa_apache.sl is loaded by Apache.
>The shared library of mod_rsawa_apache.sl call libaceauth.sl using shl_load().

yes. But how do you call the functions in libaceauth.sl? (Not that you get this far, since it is aborting when you are doing the shl_load in #9?)

/opt/aCC/bin/aCC -b -o libaceauth.sl hp11/aaa_Apache.o -lstd_v2 -lCsup_v2 -Wl,-a,archive a1.a a2.a

There is no need to use Wl,-a,archive.

>a1.a a2.a is made by using ar command (ar -r) from C++ sources.
>If you think the above is wrong, please let us know.

That's fine.
tash S
Frequent Advisor

Re: library difference between compile env. and production env.

Hi Dennis,

I changed from

return shl_load(path, BIND_IMMEDIATE | BIND_NONFATAL, 0);

to

return shl_load(path, BIND_FIRST | BIND_TOGETHER, 0);


So there is no core, I am not sure that this really solve the problem. I need the time to investigate it.

The other questions, I will try to investigate later.
Dennis Handly
Acclaimed Contributor

Re: library difference between compile env. and production env.

I would recommend never ever use BIND_FIRST. No other vendor has this.