Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 130439 - segmentation fault (11) in apache for some PHP pages
Summary: segmentation fault (11) in apache for some PHP pages
Status: RESOLVED NEEDINFO
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Server (show other bugs)
Hardware: x86 Linux
: High critical (vote)
Assignee: Gentoo Linux bug wranglers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-04-19 01:03 UTC by Steven
Modified: 2006-04-19 09:46 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Steven 2006-04-19 01:03:43 UTC
!! If anyone can help me out with this, please do. It's quiet urgent since we're working on a project with deadline wed april, 26th !!
Thx


DESCRIPTION
-----------
On some PHP-pages I get a download box instead of the expected webpage.  If I download and open the file (script.php), I can see it's empty.

The apache2 logfile sais: 
[Wed Apr 19 09:36:08 2006] [notice] child pid 19528 exit signal Segmentation fault (11)

The page in question is still in development, and is quiet heavy.  There are a lot of (nested) objects, but they are clean (no recursion in the objects or something like that)


ACTIONS TAKEN
-------------
- increased memory_limit to 64M in php.ini
- recompiled Apache2 with mpm-prefork
- Let memtest86 check memory overnight: no errors
- unmerged apache, recompiled apr & apr-util and recompiled apache (prefork) & php
- installed apache-1.3, recompiled PHP without the apache2-useflag


TEMPORARY WORKAROUND
--------------------
None found :'(


INFO
----
Portage 2.0.54 (default-linux/x86/2005.1, gcc-3.4.5, glibc-2.3.5-r2, 2.6.15-gentoo-r1 i686)
=================================================================
System uname: 2.6.15-gentoo-r1 i686 Intel(R) Pentium(R) M processor 2.00GHz
Gentoo Base System version 1.6.14
dev-lang/python:     2.3.5, 2.4.2
sys-apps/sandbox:    1.2.12
sys-devel/autoconf:  2.13, 2.59-r6
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r1
sys-devel/binutils:  2.16.1
sys-devel/libtool:   1.5.22
virtual/os-headers:  2.6.11-r2
ACCEPT_KEYWORDS="x86"
AUTOCLEAN="yes"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-O3 -march=pentium-m -mtune=pentium-m -pipe -ftracer -fomit-frame-pointer"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3.4/env /usr/kde/3.4/share/config /usr/kde/3.4/shutdown /usr/kde/3/share/config /usr/lib/X11/xkb /usr/lib/mozilla/defaults/pref /usr/share/config /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/eselect/compiler /etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-O3 -march=pentium-m -mtune=pentium-m -pipe -ftracer -fomit-frame-pointer -frepo"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoconfig distlocks sandbox sfperms strict"
GENTOO_MIRRORS="http://ftp.belnet.be/mirror/rsync.gentoo.org/gentoo/ ftp://ftp.belnet.be/mirror/rsync.gentoo.org/gentoo/"
LANG="en_US.iso88591"
LC_ALL="en_US.ISO-8859-1"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/home"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/home/ebuilds"
SYNC="rsync://rsync.be.gentoo.org/gentoo-portage"
USE="x86 X acpi alsa apache2 arts audiofile avi bash-completion berkdb bitmap-fonts bluetooth bonobo browserplugin bzip2 cdparanoia cdr crypt cups curl dri dvd dvdr dvdread eds emboss encode esd ethereal exif expat fam foomaticdb fortran gd gdbm gif gimp glut gnome gphoto2 gpm gstreamer gtk gtk2 gtkhtml hal idn imagemagick imlib isdnlog java jpeg kde lcms libg++ libwww mad mhash mikmod mng motif mozilla mp3 mpeg mysql ncurses nls nsplugin odbc ogg oggvorbis opengl oss pam pcre pdflib perl png ppds pppd python qt quicktime readline samba sdl sqlite ssl tcltk tcpd tiff truetype truetype-fonts type1-fonts udev usb vorbis win32codecs xml xml2 xmms xprint xv xvid zlib userland_GNU kernel_linux elibc_glibc"
Unset:  ASFLAGS, CTARGET, INSTALL_MASK, LDFLAGS, LINGUAS
Comment 1 Jakub Moc (RETIRED) gentoo-dev 2006-04-19 01:17:33 UTC
Reopen with 'emerge -pv apache php' output and attach some sample page that causes the segfault for you. We can't guess, sorry. Also, can you attach an strace?

strace /usr/sbin/apache2 -X -k start -D PHP4 (or PHP5, you didn't even post the PHP version you are using), telnet to apache and do something like

GET /sample.php HTTP/1.1
Host: localhost
Connection: close

then attach the strace output here...
Comment 2 Steven 2006-04-19 09:46:35 UTC
PHP Version 4.4.0-pl1-gentoo

Sorry I forgot that

It seems to be database-related. I emptied some relevant tables in my MySQL database, the problem disappeared and is still gone. Even after repopulating the tables.
If it comes back, I'll do a strace and give you more info.

(I tried with gdb this afternoon, but PHP-pages kept loading forever without a single change in the gdb output.)