perl-modperl mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jani M." <moo...@iki.fi>
Subject Re: [mp2] Segmentation faults with threaded worker-mpm
Date Wed, 06 Jun 2007 10:37:57 GMT
> Try "PerlInterpScope request" and see if the coredumps disappear. Further 
> check if it's always this place.

PerlInterpScope request did not help. I just tested, and still got a 
segfault.

As far as I have seen, all the segfaults seem to be mgv related, but not 
at the exact same spot.

One odd thing I noticed is that I have configured mod_perl to run 4 
interpreters per process, yet I always see only 2 perl threads in the 
core dumps. Is there a reason for this?

Since it looked like all the problems always occured in the FixupHandler 
phase, I tried moving the code I have there to HeaderParser phase, but 
that did not help. Here is an example backtrace from that test. Only one 
of the perl threads was in the HeaderParser phase this time - the other 
thread was polling for data from the client.

[Switching to thread 12 (process 15427)]#0  0xb7bc0d51 in kill () from 
/lib/tls/libc.so.6
#0  0xb7bc0d51 in kill () from /lib/tls/libc.so.6
#1  0x0807c9bb in ap_fatal_signal_child_setup ()
#2  <signal handler called>
#3  0xb781149d in modperl_mgv_lookup (my_perl=0x8677208, 
symbol=0x812f8c0) at modperl_mgv.c:131
#4  0xb7811562 in modperl_mgv_lookup_autoload (my_perl=0x8677208, 
symbol=0x812f8c0, s=0x80a88c8, p=0x8937320) at modperl_mgv.c:153
#5  0xb78060f1 in modperl_callback (my_perl=0x8677208, 
handler=0x8939100, p=0x8937320, r=0x8937358, s=0x80a88c8, args=0x87cca2c)
     at modperl_callback.c:75
#6  0xb7806b79 in modperl_callback_run_handlers (idx=0, type=4, 
r=0x8937358, c=0x0, s=0x80a88c8, pconf=0x0, plog=0x0, ptemp=0x0,
     run_mode=MP_HOOK_RUN_ALL) at modperl_callback.c:263
#7  0xb78070aa in modperl_callback_per_dir (idx=0, r=0x8937358, 
run_mode=MP_HOOK_RUN_ALL) at modperl_callback.c:370
#8  0xb7825a64 in modperl_header_parser_handler (r=0x8937358) at 
modperl_hooks.c:32
#9  0x080743f9 in ap_run_header_parser ()
#10 0x08071eb1 in ap_process_request_internal ()
#11 0x08084528 in ap_process_request ()
#12 0x080817de in ap_register_input_filter ()
#13 0x0807b507 in ap_run_process_connection ()
#14 0x0808914b in ap_graceful_stop_signalled ()
#15 0xb7d37316 in apr_proc_detach () from /usr/lib/libapr-1.so.0
#16 0xb7cd40bd in start_thread () from /lib/tls/libpthread.so.0
#17 0xb7c639ee in clone () from /lib/tls/libc.so.6

And here are is one more example when running in the FixupHandler phase, 
again crashing at a slightly different location.

[Switching to thread 7 (process 11705)]#0  0xb7bb1d51 in kill () from 
/lib/tls/libc.so.6
#0  0xb7bb1d51 in kill () from /lib/tls/libc.so.6
#1  0x0807c9bb in ap_fatal_signal_child_setup ()
#2  <signal handler called>
#3  0xb78022d8 in modperl_mgv_compile (my_perl=0x81cf6c0, p=0x80a20d0, 
name=0x878bc62 "MyModule") at modperl_mgv.c:98
#4  0xb7802bd1 in modperl_mgv_resolve (my_perl=0x81cf6c0, 
handler=0x88bdaf0, p=0x80a20d0,
     name=0x88bdac0 "MyApache::MyModule::proxy_rewrite_handler", 
logfailure=0) at modperl_mgv.c:275
#5  0xb77f8cb0 in modperl_handler_resolve (my_perl=0x81cf6c0, 
handp=0xb451d274, p=0x88bc3d0, s=0x80a88c8) at modperl_handler.c:233
#6  0xb77f6e73 in modperl_callback (my_perl=0x81cf6c0, 
handler=0x88bdaf0, p=0x88bc3d0, r=0x88bc408, s=0x80a88c8, args=0x88c5ea0)
     at modperl_callback.c:39
#7  0xb77f7b79 in modperl_callback_run_handlers (idx=5, type=4, 
r=0x88bc408, c=0x0, s=0x80a88c8, pconf=0x0, plog=0x0, ptemp=0x0,
     run_mode=MP_HOOK_RUN_ALL) at modperl_callback.c:263
#8  0xb77f80aa in modperl_callback_per_dir (idx=5, r=0x88bc408, 
run_mode=MP_HOOK_RUN_ALL) at modperl_callback.c:370
#9  0xb7816b63 in modperl_fixup_handler (r=0x88bc408) at modperl_hooks.c:57
#10 0x0806ff29 in ap_run_fixups ()
#11 0x08084528 in ap_process_request ()
#12 0x080817de in ap_register_input_filter ()
#13 0x0807b507 in ap_run_process_connection ()
#14 0x0808914b in ap_graceful_stop_signalled ()
#15 0xb7d28316 in apr_proc_detach () from /usr/lib/libapr-1.so.0
#16 0xb7cc50bd in start_thread () from /lib/tls/libpthread.so.0
#17 0xb7c549ee in clone () from /lib/tls/libc.so.6

--
Jani

Mime
View raw message