perl-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Phil Pennock <>
Subject segfault on global disable of mod_perl
Date Tue, 06 Jul 2004 12:15:24 GMT
-------------8<---------- Start Bug Report ------------8<----------
1. Problem Description:

If "PerlOptions -Enable" is set in global context in Apache config,
mod_perl segfaults.

I was experimenting, because of the support for cloned Perl instances
for differing vhosts, to see if the Perl handling could be enabled in only
the vhosts which explicitly required it, by disabling in global context
and explicit enabling.  Apparently not.  An error message and "don't be
stupid, and here's why it's stupid" is perhaps preferable to a segfault of

Config to replicate, using Apache2 setup:

 LoadModule perl_module libexec/apache2/
 <IfModule mod_perl.c>
   PerlModule Apache2
   PerlOptions -Enable

This using the relevant ports installed under FreeBSD, with whatever
test framework that invokes.  Removing "PerlOptions -Enable" avoids
the problem.

2. Used Components and their Configuration:

*** mod_perl version 1.9914

*** using /usr/local/lib/perl5/site_perl/5.8.4/mach/Apache2/Apache/
*** Makefile.PL options:
  MP_APXS         => /usr/local/sbin/apxs
  MP_COMPAT_1X    => 1
  MP_LIBNAME      => mod_perl
  MP_USE_DSO      => 1
  MP_USE_STATIC   => 1

*** /usr/local/sbin/httpd -V
Server version: Apache/2.0.49
Server built:   Jun 23 2004 22:30:44
Server's Module Magic Number: 20020903:7
Architecture:   32-bit
Server compiled with....
 -D APACHE_MPM_DIR="server/mpm/prefork"
 -D APR_HAVE_IPV6 (IPv4-mapped addresses enabled)
 -D HTTPD_ROOT="/usr/local"
 -D SUEXEC_BIN="/usr/local/bin/suexec"
 -D DEFAULT_PIDLOG="/var/run/"
 -D DEFAULT_SCOREBOARD="logs/apache_runtime_status"
 -D DEFAULT_LOCKFILE="/var/run/accept.lock"
 -D DEFAULT_ERRORLOG="/var/log/httpd-error.log"
 -D AP_TYPES_CONFIG_FILE="etc/apache2/mime.types"
 -D SERVER_CONFIG_FILE="etc/apache2/httpd.conf"

*** /usr/local/bin/perl -V
Summary of my perl5 (revision 5 version 8 subversion 4) configuration:
    osname=freebsd, osvers=4.10-release, archname=i386-freebsd-64int
    uname='freebsd 4.10-release freebsd 4.10-release #0: tue may
25 22:47:12 gmt 2004 i386 '
    config_args='-sde -Dprefix=/usr/local -Darchlib=/usr/local/lib/perl5/5.8.4/mach -Dprivlib=/usr/local/lib/perl5/5.8.4
-Dman3dir=/usr/local/lib/perl5/5.8.4/perl/man/man3 -Dman1dir=/usr/local/man/man1 -Duse64bitint
-Dsitearch=/usr/local/lib/perl5/site_perl/5.8.4/mach -Dsitelib=/usr/local/lib/perl5/site_perl/5.8.4
-Dscriptdir=/usr/local/bin -Dsiteman3dir=/usr/local/lib/perl5/5.8.4/man/man3 -Dsiteman1dir=/usr/local/man/man1
-Ui_malloc -Ui_iconv -Uinstallusrbinperl -Dcc=cc -Doptimize=-O -pipe -march=pentiumpro -Duseshrplib
-Dccflags=-DAPPLLIB_EXP="/usr/local/lib/perl5/5.8.4/BSDPAN" -Ud_dosuid -Ui_gdbm -Dusethreads=n
    hint=recommended, useposix=true, d_sigaction=define
    usethreads=undef use5005threads=undef useithreads=undef usemultiplicity=undef
    useperlio=define d_sfio=undef uselargefiles=define usesocks=undef
    use64bitint=define use64bitall=undef uselongdouble=undef
    usemymalloc=y, bincompat5005=undef
    cc='cc', ccflags ='-DAPPLLIB_EXP="/usr/local/lib/perl5/5.8.4/BSDPAN" -DHAS_FPSETMASK -DHAS_FLOATINGPOINT_H
-fno-strict-aliasing -I/usr/local/include',
    optimize='-O -pipe -march=pentiumpro',
    cppflags='-DAPPLLIB_EXP="/usr/local/lib/perl5/5.8.4/BSDPAN" -DHAS_FPSETMASK -DHAS_FLOATINGPOINT_H
-fno-strict-aliasing -I/usr/local/include'
    ccversion='', gccversion='2.95.4 20020320 [FreeBSD]', gccosandvers=''
    intsize=4, longsize=4, ptrsize=4, doublesize=8, byteorder=12345678
    d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=12
    ivtype='long long', ivsize=8, nvtype='double', nvsize=8, Off_t='off_t', lseeksize=8
    alignbytes=4, prototype=define
  Linker and Libraries:
    ld='cc', ldflags ='-Wl,-E  -L/usr/local/lib'
    libpth=/usr/lib /usr/local/lib
    libs=-lm -lcrypt -lutil -lc
    perllibs=-lm -lcrypt -lutil -lc
    libc=, so=so, useshrplib=true,
  Dynamic Linking:
    dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags='  -Wl,-R/usr/local/lib/perl5/5.8.4/mach/CORE'
    cccdlflags='-DPIC -fPIC', lddlflags='-shared  -L/usr/local/lib'

Characteristics of this binary (from libperl): 
  Compile-time options: USE_64_BIT_INT USE_LARGE_FILES
  Built under freebsd
  Compiled at Jun 23 2004 22:57:31

3. This is the core dump trace: (if you get a core dump):

Starting Apache2 httpd (not restart/graceful, but clean):

(gdb) bt
#0  0x28434336 in Perl_sv_vcatpvfn () from /usr/local/lib/perl5/5.8.4/mach/CORE/
#1  0x284339b5 in Perl_sv_vsetpvfn () from /usr/local/lib/perl5/5.8.4/mach/CORE/
#2  0x284118d1 in Perl_vform () from /usr/local/lib/perl5/5.8.4/mach/CORE/
#3  0x28411880 in Perl_form () from /usr/local/lib/perl5/5.8.4/mach/CORE/
#4  0x283901c5 in modperl_hook_pre_config () from /usr/local/libexec/apache2/
#5  0x8063b91 in ap_run_post_config ()
#6  0x80687e6 in main ()
#7  0x805cdba in _start ()

This report was generated by -e on Tue Jul  6 12:05:39 2004 GMT.

-------------8<---------- End Bug Report --------------8<----------

Note: Complete the rest of the details and post this bug report to
dev <at> To subscribe to the list send an empty
email to

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message