www-apache-bugdb mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Didimo Grimaldo <emilio_tu...@nl.compuware.com>
Subject os-solaris/4038: Httpd dies with SEGV when 3rd party module has threading
Date Thu, 11 Mar 1999 14:24:56 GMT

>Number:         4038
>Category:       os-solaris
>Synopsis:       Httpd dies with SEGV when 3rd party module has threading
>Confidential:   no
>Severity:       critical
>Priority:       medium
>Responsible:    apache
>State:          open
>Class:          sw-bug
>Submitter-Id:   apache
>Arrival-Date:   Thu Mar 11 06:30:01 PST 1999
>Originator:     emilio_tunon@nl.compuware.com
>Release:        1.3.3
SunOS waxmoth 5.5.1 Generic_103640-24 sun4m sparc SUNW,SPARCclassic
Sun Pro compiler version 4.0
No backtrace, dbx also coredumps after run -X so I can't do 'where'.
This occurs on some SunOS machines and is probably related to the
sun patches, though one machine with the same patch level (24) does
work while the other doesn't.

It seems that on some machines you ACTUALLY need to compile Apache with
the "-mt" CFLAG because the module is multi-threaded. If not used on
these circumstances. If not then when that module is loaded it both
libthread and libpthread are 'read'/loaded. But with "-mt" the libthread
is loaded much earlier in the startup and the problem does not occur.

A crashing session would show:
     Reading symbolic information for libpthread.so.1
     Reading symbolic information for libthread.so.1

     dbx: internal error: signal SEGV (Segmentation Fault)

A good executable however would load libthread (Solaris native) very
early, then load all the modules (mod_*) and then as last libpthread.so.1.

Side remark: Changing EXTRA_CFLAGS requires that one *also* adds the
             `$(SRCDIR)/apaci` otherwise the generated makefiles lose
             all the system-defines of the configure session!
Have a couple of Posix threads on a mod_mymodule, compile the module with
-lpthread (ie. don't use native solaris threads) and with -mt.
Will  crash when you do 'httpd -X' or simply 'httpd'.
It should work on machines that don't require an explicit -mt but I can't
affirm that. In any case -mt solves it. This of course is only valid
when building using the Sun Pro compiler.
[In order for any reply to be added to the PR database, ]
[you need to include <apbugs@Apache.Org> in the Cc line ]
[and leave the subject line UNCHANGED.  This is not done]
[automatically because of the potential for mail loops. ]
[If you do not include this Cc, your reply may be ig-   ]
[nored unless you are responding to an explicit request ]
[from a developer.                                      ]
[Reply only with text; DO NOT SEND ATTACHMENTS!         ]

View raw message