Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 32411 - apache 2.0.48 fails to start after updating
Summary: apache 2.0.48 fails to start after updating
Status: RESOLVED DUPLICATE of bug 25299
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Server (show other bugs)
Hardware: All Linux
: High major
Assignee: Gentoo Web Application Packages Maintainers
URL: http://httpd.apache.org/
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-10-31 11:23 UTC by Eric Olinger
Modified: 2005-07-17 13:06 UTC (History)
2 users (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 Eric Olinger 2003-10-31 11:23:53 UTC
To keep up on my security I updated apache from 2.0.47 to 2.0.48 today
because of the GLSA that went out. After updating and changing some of
config files over apache is failing to start.

When I run /etc/init.d/apache2 start I get:
 * Starting apache2...
/sbin/runscript.sh: line 526: 31027 Aborted                 env -i PATH=$PATH /sbin/start-stop-daemon --quiet --start --startas /usr/sbin/apache2 --pidfile /var/run/apache2.pid -- -k start ${APACHE2_OPTS}                                                            [ !! ]

I've also tried to run apache2ctl on its own but it is also failing so
I don't know where the problem lies. Running '/usr/sbin/apache2ctl start'
gives me:
/usr/sbin/apache2ctl: line 88: 31041 Aborted                 $HTTPD -k $ARGV
Comment 1 Donny Davies (RETIRED) gentoo-dev 2003-10-31 13:30:26 UTC
That's not enough information.

What does your syslog tell you.  What does the Apache error_log say.

Do you compile with -fstack-protector?  What options are enabled in
/etc/conf.d/apache2?

Comment 2 Eric Olinger 2003-10-31 13:47:57 UTC
I've tried it without the -fstack-protector also. It doesnt get far enought
along to write to the log files for apache and nothing is written to the
syslogger.
Comment 3 Eric Olinger 2003-11-03 11:14:16 UTC
I found the problem. I'm using hardened-gcc. It seems that apache2 has
some isses with the hardened-gcc package, but it works fine with the
-fstack-protector flag. 
Comment 4 Donny Davies (RETIRED) gentoo-dev 2003-11-04 10:05:50 UTC
you mean _without_ -fstack-protector right?
Comment 5 Eric Olinger 2003-11-04 10:16:10 UTC
Nope, suprisingly I still have the -fstack-ptrtector flag in the make.conf
and apache build correctly and worked. For some reason it didn't work with
the hardened-gcc packages. Which is weird because propolice is part of 
hardened-gcc, so it must be one of the other parts of hardened-gcc that
apache doesn't play nice with.
Comment 6 Donny Davies (RETIRED) gentoo-dev 2003-11-04 10:18:20 UTC
Well, if I build 2.0.48 with -fstack-protector here, my server will fail
to load libphp.so and crash with this in the syslog:

[apache2] stack overflow in function load_module

If I build without -fstack-protector, it doesnt crash.

Not sure what to do about this at the moment... bummer!
Comment 7 Ric Messier 2003-11-05 10:33:50 UTC
I have the same problem as described below. I am not using hardened-gcc.
I have tried it with both apache1 and apache2 with identical results. I get
the same result with Apache1 (after emerge unmerge apache2). PHP4.3.3. strace
shows it loading the module and then doing a bunch of java-related things.
Then it does something with /dev/log (I'm not in front of the system at the
moment -- will post more specifics shortly) and then dies. 

Obviously, not turning on -D PHP4 (not loading the module) allows apache
to start. I haven't tried it with any other modules as yet.
Comment 8 Ric Messier 2003-11-06 10:29:30 UTC
Ooops. I did have hardened gcc installed -- it was apparently in the stage3
image I started from and I didn't realize it. Once I unmerge'd it, everything
built and worked fine. 
Comment 9 Alexander Gabert (RETIRED) gentoo-dev 2003-11-25 12:53:41 UTC
thnks for this bug

try to emerge glibc with the guard@@glibc changes, then reemerge gcc with this change: http://dev.gentoo.org/~pappy/gentoo-x86/sys-devel/gcc/gcc-3.2.3-r2.ebuild.diff
do not forget to fetch the file from the dir and move it to the appropriate filesdir to get the patch going

then emerge hardened-gcc, check for hcc.conf and hcc -a to be good
then reemerge apache and mod_php

btw: try starting apache2 without -D PHP4, this works, with -D PHP4 and full propolice compiled it does not work and tells about stack smash handling.

why does it work without hardened-gcc and only CFLAGS then?

simply put: because the ebuilds or makefiles throw away the stack protection CFLAGS.

thanks again for giving the example with the problems described.

*** This bug has been marked as a duplicate of 25299 ***