Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 347782 - www-servers/apache-2.2.16 + dev-lang/php-5.3.3 crashed with "Segmentation fault (11)"
Summary: www-servers/apache-2.2.16 + dev-lang/php-5.3.3 crashed with "Segmentation fau...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: x86 Linux
: High normal (vote)
Assignee: Apache Team - Bugzilla Reports
URL:
Whiteboard:
Keywords:
: 347785 347918 (view as bug list)
Depends on: 342055
Blocks: gcc-4.5
  Show dependency tree
 
Reported: 2010-12-05 08:49 UTC by Dan Johansson
Modified: 2011-04-12 23:29 UTC (History)
9 users (show)

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


Attachments
Tracefile from "strace -f -o /var/tmp/apache_strace.txt /etc/init.d/apache2 start" (apache_strace.txt,625.31 KB, text/plain)
2010-12-05 09:01 UTC, Dan Johansson
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Dan Johansson 2010-12-05 08:49:35 UTC
Today I emerged mysql, apache, PHP5, phpmyadmin and joomla on a ~x86 host to be able to play a bit with Joomla.
But I can not get phpmyadmin or Joomla to work (both with the same error).

Mysql and apache starts OK and the the phpmyadmin setup page (http://localhost/phpmyadmin/setup) loads fine - but when I press the Save-button all I get back is a blank page (the same is true for Joomla - after selecting the language and pressing Next - all I get is a black page)-
In apache's error-log I see the following in both cases:

[Sat Dec 04 19:54:35 2010] [notice] child pid 3134 exit signal Segmentation fault (11)

I've had a look at bugs.gentoo.org but could not find anything with php-5.3.3 or Apache-2.2.16 (just with older versions of php and Apache). That's why I'm opening a new bug.


Reproducible: Always

Steps to Reproduce:
1. Point browser to http://localhost/phpmyadmin/setup
2. Click Save


Actual Results:  
Blank page appears and "Segmentation fault" error message in the apache error log.

Expected Results:  
The phpmyadmin page should appear and no error in the error log.

Portage 2.1.9.25 (default/linux/x86/10.0/desktop/kde, gcc-4.5.1, glibc-2.12.1-r3, 2.6.36-gentoo-r3 i686)
=================================================================
System uname: Linux-2.6.36-gentoo-r3-i686-Intel-R-_Core-TM-2_CPU_T7200_@_2.00GHz-with-gentoo-2.0.1
Timestamp of tree: Sat, 04 Dec 2010 09:30:01 +0000
app-shells/bash:     4.1_p9
dev-lang/python:     2.7.1, 3.1.3
dev-util/cmake:      2.8.1-r2
sys-apps/baselayout: 2.0.1-r1
sys-apps/openrc:     0.6.7
sys-apps/sandbox:    2.4
sys-devel/autoconf:  2.13, 2.68
sys-devel/automake:  1.9.6-r3, 1.10.3, 1.11.1
sys-devel/binutils:  2.20.1-r1
sys-devel/gcc:       4.5.1-r1
sys-devel/gcc-config: 1.4.1
sys-devel/libtool:   2.4-r1
sys-devel/make:      3.82
virtual/os-headers:  2.6.36.1 (sys-kernel/linux-headers)
ACCEPT_KEYWORDS="x86 ~x86"
ACCEPT_LICENSE="*"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-O2 -march=native -pipe"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/config"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/php/apache2-php5.3/ext-active/ /etc/php/cgi-php5.3/ext-active/ /etc/php/cli-php5.3/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-O2 -march=native -pipe"
DISTDIR="/usr/portage/distfiles"
EMERGE_DEFAULT_OPTS="--with-bdeps y"
FEATURES="assume-digests binpkg-logs distlocks fixlafiles fixpackages news parallel-fetch protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch"
GENTOO_MIRRORS="http://mirror.switch.ch/ftp/mirror/gentoo/ http://de-mirror.org/distro/gentoo/ http://gentoo.osuosl.org/"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
LINGUAS="en en_US de se sv sv_SE"
MAKEOPTS="-j3"
PKGDIR="/var/pkgdir"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="X a52 aac acl acpi alsa apache2 bash-completion berkdb bluetooth branding bzip2 cairo cdr cli consolekit cracklib crypt cups curl cxx dbus dri dts dvd dvdr emboss enca encode exif fam firefox flac gd gdbm gif gtk hal iconv idn jpeg kde lcms ldap libnotify mad mikmod mmx mng modules mp3 mp4 mpeg mudflap mysql ncurses network-cron nls nptl nptlonly ogg opengl openmp pae pam pango pcre pdf perl png ppds pppd python qt3support qt4 readline sdl session spell sse sse2 ssl ssse3 startup-notification svg sysfs tcpd tiff truetype unicode usb vim-syntax vorbis x264 x86 xcb xml xorg xulrunner xv xvid zlib" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1 emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mmap_emul mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ubx" INPUT_DEVICES="evdev synaptics" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="en en_US de se sv sv_SE" PHP_TARGETS="php5-2" RUBY_TARGETS="ruby18" USERLAND="GNU" VIDEO_CARDS="ati radeon" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account" 
Unset:  CPPFLAGS, CTARGET, FFLAGS, INSTALL_MASK, LANG, LC_ALL, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, PORTDIR_OVERLAY

 emerge --verbose --pretend mysql apache php

These are the packages that would be merged, in order:

Calculating dependencies... done!
[ebuild   R   ] www-servers/apache-2.2.16-r1  USE="ldap ssl -debug -doc (-selinux) -static -suexec -threads" APACHE2_MODULES="actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias -asis -auth_digest -authn_dbd -cern_meta -charset_lite -dbd -dumpio -ident -imagemap -log_forensic -proxy -proxy_ajp -proxy_balancer -proxy_connect -proxy_ftp -proxy_http -proxy_scgi -reqtimeout -substitute -version" APACHE2_MPMS="-event -itk -peruser -prefork -worker" 0 kB                                                                                                
[ebuild   R   ] dev-db/mysql-5.1.53  USE="community perl ssl -big-tables -cluster (-debug) -embedded -extraengine -latin1 -max-idx-128 -minimal -pbxt -profiling (-selinux) -static -test -xtradb" 0 kB                                                                                                                                                                     
[ebuild   R   ] dev-lang/php-5.3.3-r3  USE="apache2 berkdb bzip2 cli crypt ctype curl exif fileinfo filter gd gdbm gmp hash iconv json ldap mysql nls phar posix readline session simplexml ssl tokenizer truetype unicode xml xmlreader xmlwriter zip zlib -adabas -bcmath -birdstep -calendar -cdb -cgi -cjk -curlwrappers -db2 -dbmaker -debug -doc -embed -empress -empress-bcs -enchant -esoob -firebird -flatfile -fpm -frontbase -ftp -gd-external -imap -inifile -interbase -intl -iodbc -ipv6 -kerberos -kolab -ldap-sasl -libedit -mssql -mysqli -mysqlnd -oci8 -oci8-instant-client -odbc -pcntl -pdo -pic -postgres -qdbm -recode -sapdb -sharedext -sharedmem -snmp -soap -sockets -solid -spell -sqlite -sqlite3 -suhosin -sybase-ct -sysvipc -threads -tidy -wddx -xmlrpc -xpm -xsl" 0 kB                                                                                                                                      

I have tried to compile Apache with APACHE2_MPMS="prefork" as well with the same result.
Comment 1 Dan Johansson 2010-12-05 09:01:05 UTC
Created attachment 256370 [details]
Tracefile from "strace -f -o /var/tmp/apache_strace.txt /etc/init.d/apache2 start"
Comment 2 Holger Hoffstätte 2010-12-05 09:11:33 UTC
This is a wrong-code bug with gcc 4.5.1, see:
http://forums.gentoo.org/viewtopic-t-855112.html

If you revert to gcc-4.4.5 and rebuild apache it should work.
Comment 3 Dan Johansson 2010-12-05 09:59:08 UTC
Yes, after reverting back to gcc-4.4.5 it's working again.

Do you know if there is a bug open for this gcc problem here at bugs.gentoo.org?
I could not find one...

Thanks for you support and keep up the good work.
Comment 4 Dan Johansson 2010-12-05 11:24:20 UTC
A new bug has been opened for gcc (http://bugs.gentoo.org/show_bug.cgi?id=347785)
Comment 5 Jeroen Roovers (RETIRED) gentoo-dev 2010-12-06 19:42:11 UTC
*** Bug 347785 has been marked as a duplicate of this bug. ***
Comment 6 Magnus Granberg gentoo-dev 2010-12-08 17:12:13 UTC
*** Bug 347918 has been marked as a duplicate of this bug. ***
Comment 7 Federico Cuello 2010-12-22 18:31:29 UTC
Had a similar issue with mod_ssl segfault'ing all the time and "fixed" it compiling apache with CFLAGS "-O" (not -O2 nor -O3)

See:

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46488

Comment 8 Hodur 2010-12-29 10:17:36 UTC
(In reply to comment #0)

Same problem with gcc-4.5.2 and apache-2.2.17
Comment 9 Emmanuel Andry 2011-01-11 11:34:23 UTC
See Mandriva ticket : https://qa.mandriva.com/show_bug.cgi?id=61384

It seems that the problem doesn't occurs with apache 2.2.17 (per comment #28)
Comment 10 Kobi Braendli 2011-02-16 14:49:58 UTC
(In reply to comment #9)
> See Mandriva ticket : https://qa.mandriva.com/show_bug.cgi?id=61384
> 
> It seems that the problem doesn't occurs with apache 2.2.17 (per comment #28)
> 

The bug can be fixed by applying the apr patch given in bug 355171 
Comment 11 Benedikt Böhm (RETIRED) gentoo-dev 2011-02-18 17:28:56 UTC
should be fixed with apache 2.2.17
Comment 12 Marcin Mirosław 2011-04-12 13:44:36 UTC
Still the same, x86, hardened, apache-2.2.17:
[241429.463649] PAX: From x.x.x.x: execution attempt in: (null), 00000000-00000000 00000000
[241429.463654] PAX: terminating task: /usr/sbin/apache2(apache2):19213, uid/euid: 81/81, PC: 00000058, SP: b383e6dc
[241429.463659] PAX: bytes at PC: ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? 
[241429.463706] PAX: bytes at SP-4: 00000000 aa7aa936 1b6a6c64 b383e708 b383e704 00000000 b383e760 1b6cfdcc b383e708 b383e704 00000020 0000007e 1b6dab76 a436b5fe 1b522340 00000fac aa7aa879 aa2b5894 00000000 1b6cfdc8 1b66f110
Comment 13 Ryan Hill (RETIRED) gentoo-dev 2011-04-12 23:29:51 UTC
File a new bug.