php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #10787 mod_perl and php4 -> Segmentation fault
Submitted: 2001-05-10 09:47 UTC Modified: 2001-06-25 05:23 UTC
From: red at rosa dot com Assigned:
Status: Closed Package: Reproducible crash
PHP Version: 4.0.5 OS: RH6.2 kernel2.4.3
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: red at rosa dot com
New email:
PHP Version: OS:

 

 [2001-05-10 09:47 UTC] red at rosa dot com
I have no chance to get php4.0.5 working with mod_perl (1.25). Some Child Processes are Segfaulting... I even tried to run 2 apache servers: one only with php and one with mod_perl and connect them with a ProxyPass... The apache processes with php are still crashing! I also tried every combination of dso and compiled in modules... Nothing helped.

PHP4.0.5 was working fine until I tried to use mod_perl...

./configure --with-apxs=/usr/local/apache/bin/apxs --enable-xml --with-dom --with-gd --with-ttf --with-smtp --with-imap=/usr/local/src/imap-4.7 --enable-track-vars --enable-force-cgi-redirect --with-gettext --with-pgsql --with-mysql=/usr

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2001-05-10 09:49 UTC] derick@php.net
Hello,

can you post a backtrace of this crash?

Derick
 [2001-05-10 09:50 UTC] derick@php.net
Status: feedback (again)
 [2001-05-10 10:33 UTC] red at rosa dot com
Sorry, I didn't get it, cause the httpd with -X is getting to slow... 
 [2001-05-10 10:45 UTC] derick@php.net
Hello,

that answer made little sense to me. Can you explain it a litte more?
Please also include the output of "ldd httpd" (where httpd is your new apache executable).

regards,
Derick
 [2001-05-10 12:05 UTC] red at rosa dot com
result of ldd:
        libm.so.6 => /lib/libm.so.6 (0x40019000)
        libcrypt.so.1 => /lib/libcrypt.so.1 (0x40036000)
        libdb.so.3 => /lib/libdb.so.3 (0x40064000)
        libdl.so.2 => /lib/libdl.so.2 (0x4009e000)
        libc.so.6 => /lib/libc.so.6 (0x400a3000)
        /lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x40000000)

result of bt:
#0  0x401beea7 in ?? () from /usr/local/apache/libexec/libphp4.so
#1  0x401ba2f5 in ?? () from /usr/local/apache/libexec/libphp4.so
#2  0x401bae07 in ?? () from /usr/local/apache/libexec/libphp4.so
#3  0x405f0d5a in ?? () from /usr/local/apache/libexec/libphp4.so
#4  0x4059e02c in ?? () from /usr/local/apache/libexec/libphp4.so
#5  0x405f1023 in ?? () from /usr/local/apache/libexec/libphp4.so
#6  0x4059ab64 in ?? () from /usr/local/apache/libexec/libphp4.so
#7  0x4059e02c in ?? () from /usr/local/apache/libexec/libphp4.so
#8  0x40598120 in ?? () from /usr/local/apache/libexec/libphp4.so
#9  0x405afe99 in ?? () from /usr/local/apache/libexec/libphp4.so
#10 0x405ace35 in ?? () from /usr/local/apache/libexec/libphp4.so
#11 0x807620e in run_cleanups ()
#12 0x8074a3d in ap_clear_pool ()
#13 0x8074ab1 in ap_destroy_pool ()
#14 0x80846bd in child_main ()
#15 0x80847fc in make_child ()
#16 0x8084959 in startup_children ()
#17 0x8084f96 in standalone_main ()
#18 0x8085723 in main ()
#19 0x400bb9cb in __libc_start_main (main=0x80853dc <main>, argc=4,
    argv=0xbffff99c, init=0x804f494 <_init>, fini=0x80b9eac <_fini>,
    rtld_fini=0x4000aea0 <_dl_fini>, stack_end=0xbffff994)
    at ../sysdeps/generic/libc-start.c:92

 [2001-05-10 12:35 UTC] sniper@php.net
Try linking apache with phtread library.
Instructions how it's done can be found on this page:

http://wwwp.php.net/oci8

--Jani

 [2001-05-10 13:31 UTC] red at rosa dot com
Done...

ldd looks now like this:
ldd /usr/local/apache/bin/httpd
        libpthread.so.0 => /lib/libpthread.so.0 (0x40019000)
        libm.so.6 => /lib/libm.so.6 (0x4002c000)
        libcrypt.so.1 => /lib/libcrypt.so.1 (0x40049000)
        libdb.so.3 => /lib/libdb.so.3 (0x40077000)
        libdl.so.2 => /lib/libdl.so.2 (0x400b2000)
        libc.so.6 => /lib/libc.so.6 (0x400b6000)
        /lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x40000000)

I think I'll let it run now for a while and will check if it runs stable now... Bye the way could you please try to explain what I should do, that I don't have to care about libpthread in the future?
 [2001-05-10 13:57 UTC] red at rosa dot com
It is still segfaulting
 [2001-05-10 18:45 UTC] sniper@php.net
Do these steps for PHP:

rm config.cache
./configure <your options + --enable-debug> 
make clean
make
make install

And you should get better backtrace of the crash.
Although it looks like it doesn't even touch PHP..

What is the version of Apache used?


 [2001-05-11 05:59 UTC] red at rosa dot com
This was the backtrace with --enable-debug... The apache version is 1.3.19
 [2001-05-14 08:12 UTC] sniper@php.net
Is the mod_perl compiled as DSO?
If so, try moving the LoadModule line for it before php4
module is loaded.

If not, compile it as DSO and do that.

--Jani

 [2001-05-14 08:12 UTC] sniper@php.net
FYI: I have mod_perl 1.25 and PHP 4 in my Apache and I 
have no problems.

 [2001-05-14 11:09 UTC] red at rosa dot com
Well I have to believe you, but I have these problems, and no Idea how to fix it... The only thing I know is, that these problems are occuring since I installed mod_perl. But the processes crashing are those with php... So I hoped that you php-guys eventualy know something about these issues. Thank you anyway...
Red
 [2001-05-14 11:11 UTC] red at rosa dot com
A yeah... I loaded mod_perl before php in the httpd. (Found this in some newsgroups). But without success...
 [2001-05-14 23:36 UTC] sniper@php.net
This is not any bug in PHP. So please ask further
questions on the mailing lists, php-general / php-install

 [2001-06-25 05:23 UTC] red at rosa dot com
Well, I just installed php 4.0.6 and it is working well 
now. So, there was no bug in php, huh? ;) 

sorry, I couldn't resist to write this...

 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Tue May 06 00:01:29 2025 UTC