You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by Janek Bogucki <ya...@purpleturtle.com> on 2001/09/22 02:11:29 UTC

Solution to mod_webapp.so:undefined symbol: pthread_sigmask on Red Hat Linux 7.1

Hi,

I may have solved (or at least worked around) the the missing
'pthread_sigmask' symbol error encountered when trying to use
mod_webapp.so. From the mailing list it appears to affect this
configuration:

   1. Red Hat Linux 7.1

   2. Apache 1.3.x
   
   3. httpd.conf will have these lines in it:

         LoadModule webapp_module      libexec/mod_webapp.so
         AddModule mod_webapp.c

The symptom is this:

    [root@bogucki bin]# ./apachectl start
    Syntax error on line 241 of /opt/apache/conf/httpd.conf:
    Cannot load /opt/apache/libexec/mod_webapp.so into server:
          /opt/apache/libexec/mod_webapp.so: undefined symbol:
          pthread_sigmask
    ./apachectl start: httpd could not be started
    [root@bogucki bin]# 

The solution is:

    [root@bogucki bin]# export LD_PRELOAD=/lib/i686/libpthread-0.9.so
    [root@bogucki bin]# ./apachectl start
    ./apachectl start: httpd started
    [root@bogucki bin]# 

I am cautious in my proposal of this as the 'solution' as I'm
unaware of any ill side-effects this may have. I have not yet
tested mod_webapp.so now that finally I have httpd up with
mod_webapp.so. I'm saving that for later :-)

----------------------------------------

It might be useful if I describe the path I took to get to this
solution:


Step 1.

I located all libpthread.so's on my system:

    [root@bogucki conf]# locate libpthread.so
    /usr/lib/libpthread.so
    /lib/i686/libpthread.so.0
    /lib/libpthread.so.0
    [root@bogucki conf]# 

These are symbolic links pointing to these libraries:

    /lib/i686/libpthread-0.9.so
    /lib/libpthread-0.9.so

Step 2.

I listed the symbols in each, looking for 'pthread_sigmask':

    
    [root@bogucki conf]# nm /lib/libpthread-0.9.so 
    nm: /lib/libpthread-0.9.so: no symbols
    [root@bogucki conf]# 
    
    [root@bogucki conf]# nm /lib/i686/libpthread-0.9.so |wc
        501    1409   15588
    [root@bogucki conf]# nm /lib/i686/libpthread-0.9.so |grep sigmask
    00009640 T pthread_sigmask
    [root@bogucki conf]#

(Why would a library not have any symbols? Anyone know?)

Step 3.

I forced the preloading of the library with symbols in via
LD_PRELOAD and httpd started and served out on http://127.0.0.1 okay.

----------------------------------------

I would be interested to hear if this works for anyone else and
if any weirdnesses can be expected as a result of this
workaround.

all the best,
yan


      - This email has been sent using TurtleMail -         
Get your free email address from www.purpleturtle.com now!

Re: Solution to mod_webapp.so:undefined symbol: pthread_sigmask on Red Hat Linux 7.1

Posted by Pier Fumagalli <pi...@betaversion.org>.
"Justin Erenkrantz" <je...@ebuilt.com> wrote:

> On Sat, Sep 22, 2001 at 01:11:29AM +0000, Janek Bogucki wrote:
>> Hi,
>> 
>> I may have solved (or at least worked around) the the missing
>> 'pthread_sigmask' symbol error encountered when trying to use
>> mod_webapp.so. From the mailing list it appears to affect this
>> configuration:
> 
> This would be expected as APR is being built with threads and
> Apache 1.3 is non-threaded (and doesn't link in pthread).
> 
> Based on what I can tell in the jakarta-tomcat-connectors
> repository, Pier looks like he has addressed this issue because
> he sets APR_CFGFLG appropriately.
> 
> APR_CFGFLG="--enable-static --disable-shared --disable-threads"
> 
> This line appeared on 15-Sep-01 in revision 1.33 of configure.in.
> So, I would recommend the better solution is to use the latest
> CVS copy of mod_webapp.  HTH.  -- justin

Correct (as always).... I fixed that a loooong time ago :)

    Pier


Re: Solution to mod_webapp.so:undefined symbol: pthread_sigmask on Red Hat Linux 7.1

Posted by Justin Erenkrantz <je...@ebuilt.com>.
On Sat, Sep 22, 2001 at 01:11:29AM +0000, Janek Bogucki wrote:
> Hi,
> 
> I may have solved (or at least worked around) the the missing
> 'pthread_sigmask' symbol error encountered when trying to use
> mod_webapp.so. From the mailing list it appears to affect this
> configuration:

This would be expected as APR is being built with threads and
Apache 1.3 is non-threaded (and doesn't link in pthread).

Based on what I can tell in the jakarta-tomcat-connectors
repository, Pier looks like he has addressed this issue because
he sets APR_CFGFLG appropriately.

APR_CFGFLG="--enable-static --disable-shared --disable-threads"

This line appeared on 15-Sep-01 in revision 1.33 of configure.in.
So, I would recommend the better solution is to use the latest
CVS copy of mod_webapp.  HTH.  -- justin


Re: Solution to mod_webapp.so:undefined symbol: pthread_sigmask on Red Hat Linux 7.1

Posted by Pier Fumagalli <pi...@betaversion.org>.
"Janek Bogucki" <ya...@purpleturtle.com> wrote:

> Hi,
> 
> I may have solved (or at least worked around) the the missing
> 'pthread_sigmask' symbol error encountered when trying to use
> mod_webapp.so. From the mailing list it appears to affect this
> configuration:
> 
>  1. Red Hat Linux 7.1
> 
>  2. Apache 1.3.x
>  
>  3. httpd.conf will have these lines in it:
> 
>        LoadModule webapp_module      libexec/mod_webapp.so
>        AddModule mod_webapp.c
> 
> The symptom is this:
> 
>   [root@bogucki bin]# ./apachectl start
>   Syntax error on line 241 of /opt/apache/conf/httpd.conf:
>   Cannot load /opt/apache/libexec/mod_webapp.so into server:
>         /opt/apache/libexec/mod_webapp.so: undefined symbol:
>         pthread_sigmask
>   ./apachectl start: httpd could not be started
>   [root@bogucki bin]#
> 
> The solution is:
> 
>   [root@bogucki bin]# export LD_PRELOAD=/lib/i686/libpthread-0.9.so
>   [root@bogucki bin]# ./apachectl start
>   ./apachectl start: httpd started
>   [root@bogucki bin]#
> 
> I am cautious in my proposal of this as the 'solution' as I'm
> unaware of any ill side-effects this may have. I have not yet
> tested mod_webapp.so now that finally I have httpd up with
> mod_webapp.so. I'm saving that for later :-)
> 
> ----------------------------------------
> 
> It might be useful if I describe the path I took to get to this
> solution:
> 
> 
> Step 1.
> 
> I located all libpthread.so's on my system:
> 
>   [root@bogucki conf]# locate libpthread.so
>   /usr/lib/libpthread.so
>   /lib/i686/libpthread.so.0
>   /lib/libpthread.so.0
>   [root@bogucki conf]#
> 
> These are symbolic links pointing to these libraries:
> 
>   /lib/i686/libpthread-0.9.so
>   /lib/libpthread-0.9.so
> 
> Step 2.
> 
> I listed the symbols in each, looking for 'pthread_sigmask':
> 
>   
>   [root@bogucki conf]# nm /lib/libpthread-0.9.so
>   nm: /lib/libpthread-0.9.so: no symbols
>   [root@bogucki conf]#
>   
>   [root@bogucki conf]# nm /lib/i686/libpthread-0.9.so |wc
>       501    1409   15588
>   [root@bogucki conf]# nm /lib/i686/libpthread-0.9.so |grep sigmask
>   00009640 T pthread_sigmask
>   [root@bogucki conf]#
> 
> (Why would a library not have any symbols? Anyone know?)
> 
> Step 3.
> 
> I forced the preloading of the library with symbols in via
> LD_PRELOAD and httpd started and served out on http://127.0.0.1 okay.
> 
> ----------------------------------------
> 
> I would be interested to hear if this works for anyone else and
> if any weirdnesses can be expected as a result of this
> workaround.

AFAIK, this has been fixed a looong time ago, if you download the latest
webapp module sources (the one coming with Tomcat 4.0 final) it should be
more than fine (I tried it myself on RH71)


Re: Error running ./configure of webapp-module-1.0-tc40

Posted by Pier Fumagalli <pi...@betaversion.org>.
Hmm... It seems that there are some troubles with building for Apache 2.0
(which integrates APR as its core foundation)...

Can you please send me (privately, not to clog the list) the output of
"ls -laR /software/apache/httpd/apache-2_0_16"??

Thanks

    Pier

"Allan Kamau" <hu...@yahoo.com> wrote:

> I forgot to say that the APRVARS file does exist in
> the /apr directory in the directory where I am running
> ./configure
> 
> --- Allan Kamau <hu...@yahoo.com> wrote:
>> Hi all,
>> I am getting an error during the ./configure of
>> webapp-module-1.0-tc40 in my RH 7.1 box running
>> Apache
>> 2.0.16
>> this is what I get.
>> #./configure
>> 
> --prefix=/software/apache/jakarta/tomcat/web-app-module-1.0.tc.4.0
>> 
> --with-apxs=/software/apache/httpd/apache-2_0_16/bin/apxs
>> --enable-java=$JAVA_HOME --with-tomat=$CATALINA_HOME
>> --with-apr
>> ....
>> ...
>> ...
>> lots of error free output
>> ...
>> Finishing up 
>> checking for APR compilation flags... error
>> configure: error: Cannot find required APRVARS file
>> #
>> 
>> How can I solve this.
>> 
>> Thanks.
>> Allan Kamau.
>> 
>> 
>> 
>> __________________________________________________
>> Do You Yahoo!?
>> Get email alerts & NEW webcam video instant
>> messaging with Yahoo! Messenger. http://im.yahoo.com
> 
> 
> __________________________________________________
> Do You Yahoo!?
> Get email alerts & NEW webcam video instant messaging with Yahoo! Messenger.
> http://im.yahoo.com
> 
> 


Re: Error running ./configure of webapp-module-1.0-tc40

Posted by Allan Kamau <hu...@yahoo.com>.
I forgot to say that the APRVARS file does exist in
the /apr directory in the directory where I am running
./configure

--- Allan Kamau <hu...@yahoo.com> wrote:
> Hi all,
> I am getting an error during the ./configure of
> webapp-module-1.0-tc40 in my RH 7.1 box running
> Apache
> 2.0.16
> this is what I get.
> #./configure
>
--prefix=/software/apache/jakarta/tomcat/web-app-module-1.0.tc.4.0
>
--with-apxs=/software/apache/httpd/apache-2_0_16/bin/apxs
> --enable-java=$JAVA_HOME --with-tomat=$CATALINA_HOME
> --with-apr
> ....
> ...
> ...
> lots of error free output
> ...
> Finishing up 
> checking for APR compilation flags... error 
> configure: error: Cannot find required APRVARS file
> #
> 
> How can I solve this.
> 
> Thanks.
> Allan Kamau.
> 
> 
> 
> __________________________________________________
> Do You Yahoo!?
> Get email alerts & NEW webcam video instant
> messaging with Yahoo! Messenger. http://im.yahoo.com


__________________________________________________
Do You Yahoo!?
Get email alerts & NEW webcam video instant messaging with Yahoo! Messenger. http://im.yahoo.com

Error running ./configure of webapp-module-1.0-tc40

Posted by Allan Kamau <hu...@yahoo.com>.
Hi all,
I am getting an error during the ./configure of
webapp-module-1.0-tc40 in my RH 7.1 box running Apache
2.0.16
this is what I get.
#./configure
--prefix=/software/apache/jakarta/tomcat/web-app-module-1.0.tc.4.0
--with-apxs=/software/apache/httpd/apache-2_0_16/bin/apxs
--enable-java=$JAVA_HOME --with-tomat=$CATALINA_HOME
--with-apr
....
...
...
lots of error free output
...
Finishing up 
checking for APR compilation flags... error 
configure: error: Cannot find required APRVARS file
#

How can I solve this.

Thanks.
Allan Kamau.



__________________________________________________
Do You Yahoo!?
Get email alerts & NEW webcam video instant messaging with Yahoo! Messenger. http://im.yahoo.com