Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 56588 - apache segfaults in ap_update_vhost_given_ip when accessed for the first time
Summary: apache segfaults in ap_update_vhost_given_ip when accessed for the first time
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Server (show other bugs)
Hardware: x86 Linux
: High critical (vote)
Assignee: Apache Team - Bugzilla Reports
Depends on:
Reported: 2004-07-09 21:02 UTC by Henry So, Jr.
Modified: 2005-04-23 20:10 UTC (History)
0 users

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

The output of strace /usr/sbin/apache2 -X (strace.out,69.13 KB, text/plain)
2004-07-09 21:04 UTC, Henry So, Jr.
the output of gdb /usr/sbin/apache2 (gdb.out,973 bytes, text/plain)
2004-07-09 21:04 UTC, Henry So, Jr.
My working configure for the upstream tarball (CONFIG,1.54 KB, text/plain)
2004-07-11 07:20 UTC, Henry So, Jr.

Note You need to log in before you can comment on or make changes to this bug.
Description Henry So, Jr. 2004-07-09 21:02:47 UTC
On every apache ebuild since 2.0.49-r1, apache segfaults upon first access.  If not run in debug mode (-X), the apache process itself does not die, but the thread does, producing a message such as this in /var/log/apache2/error_log:

[Fri Jul 09 23:03:22 2004] [notice] child pid 5161 exit signal Segmentation fault (11)

If run in debug mode, the apache process will die, leaving a zombie-like process in the background that must be killed.

The page I'm attempting to access is a straight index.html page.

The apache-2.0.49 ebuild (which is no longer in portage, but available in the CVS attic) works fine.

Reproducible: Always
Steps to Reproduce:
1. emerge apache-2.0.50
2. run /sbin/apache2 -X
3. run lynx http://localhost

Actual Results:  
Lynx fails to open the page because the thread servicing it has segfaulted.

Expected Results:  
I would expect the page to be served.

root@tsubame(47)# emerge info
Portage 2.0.50-r8 (default-x86-1.4, gcc-3.3.3, glibc-, 2.4.25)
System uname: 2.4.25 i686 Intel(R) Xeon(TM) CPU 2.40GHz
Gentoo Base System version 1.4.16
Autoconf: sys-devel/autoconf-2.59-r3
Automake: sys-devel/automake-1.8.3
CFLAGS="-march=pentium3 -O2 -pipe"
CONFIG_PROTECT="/etc /usr/X11R6/lib/X11/xkb /usr/kde/2/share/config
/usr/kde/3.2/share/config /usr/kde/3/share/config /usr/lib/mozilla/defaults/pref
/usr/share/config /usr/share/texmf/dvipdfm/config/
/usr/share/texmf/dvips/config/ /usr/share/texmf/tex/generic/config/
/usr/share/texmf/tex/platex/config/ /usr/share/texmf/xdvi/ /var/bind
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-march=pentium3 -O2 -pipe"
FEATURES="autoaddcvs ccache sandbox"
USE="X alsa apache2 apm arts audiofile avi berkdb bonobo cdr crypt cups encode
esd foomaticdb gdbm gif gimpprint gnome gpm gtk gtk2 gtkhtml guile imap imlib
jack java joystick jpeg kde libg++ libwww mad mikmod motif mozilla moznocompose
moznoirc moznomail mozsvg mpeg mysql ncurses nls oggvorbis opengl oss pam pdflib
perl png postgres ppds python qt quicktime readline ruby ruby18 scanner sdl
slang spell ssl svga tcltk tcpd tetex tiff truetype x86 xml2 xmms xv zlib"

Please find attached the output of strace and gdb.
Comment 1 Henry So, Jr. 2004-07-09 21:04:00 UTC
Created attachment 35095 [details]
The output of strace /usr/sbin/apache2 -X
Comment 2 Henry So, Jr. 2004-07-09 21:04:38 UTC
Created attachment 35096 [details]
the output of gdb /usr/sbin/apache2
Comment 3 Chuck Short (RETIRED) gentoo-dev 2004-07-10 06:39:45 UTC
Please submit bug with
Comment 4 Henry So, Jr. 2004-07-11 07:19:25 UTC
I would like to report this upstream, but the upstream package (distfiles/httpd-2.0.50.tar.gz) works fine, even after I enabled the modules as specified by my unmodified /etc/apache2/apache2-builtin-mods.

From this, I can only conclude that it has something to do with how the ebuild is patching or configuring the package.  If I am still to report this upstream, perhaps you can give me a little help with my upstream bug report as to how gentoo is doing things differently.

I will attach a script indicating how I configured the upstream package.
Comment 5 Henry So, Jr. 2004-07-11 07:20:45 UTC
Created attachment 35180 [details]
My working configure for the upstream tarball
Comment 6 Elfyn McBratney (beu) (RETIRED) gentoo-dev 2004-09-27 11:47:54 UTC
Seems to be fixed in 2.0.51-r1.
Comment 7 Henry So, Jr. 2004-10-15 19:50:52 UTC
This finally works again for me in 2.0.52.
Comment 8 Elfyn McBratney (beu) (RETIRED) gentoo-dev 2005-04-23 20:10:04 UTC