Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 151711 - net-www/apache-2.0.59-r1 init script finds no running apache2
Summary: net-www/apache-2.0.59-r1 init script finds no running apache2
Status: RESOLVED INVALID
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: x86 Linux
: High minor (vote)
Assignee: Apache Team - Bugzilla Reports
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-10-17 09:30 UTC by Ilya Eremin
Modified: 2007-10-08 21:47 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 Ilya Eremin 2006-10-17 09:30:44 UTC
I have just updated to 2.0.59-r1, updated the init.d script and decided to restart apache, however it says:
No /usr/sbin/apache2 found running; none killed.

ps aux clearly shows apache running

apache   13559  1.5  1.7 270640 36868 ?        Sl   17:09   0:02 /usr/sbin/apache2 -D DEFAULT_VHOST -D PHP5 -D SSL -d /usr/li
apache   13667  0.8  1.0 254024 22100 ?        Sl   17:09   0:01 /usr/sbin/apache2 -D DEFAULT_VHOST -D PHP5 -D SSL -d /usr/li
apache   13761  0.6  1.0 254152 21936 ?        Sl   17:09   0:01 /usr/sbin/apache2 -D DEFAULT_VHOST -D PHP5 -D SSL -d /usr/li
apache   13951  0.8  1.2 257960 26608 ?        Sl   17:09   0:01 /usr/sbin/apache2 -D DEFAULT_VHOST -D PHP5 -D SSL -d /usr/li
apache   14223  0.5  1.1 254628 23208 ?        Sl   17:09   0:00 /usr/sbin/apache2 -D DEFAULT_VHOST -D PHP5 -D SSL -d /usr/li
apache   19634  0.6  1.2 257352 25020 ?        Sl   17:09   0:00 /usr/sbin/apache2 -D DEFAULT_VHOST -D PHP5 -D SSL -d /usr/li

So now the only way to restart apache is to restart the system (which I frankly rather not do)
Comment 1 Michael Stewart (vericgar) (RETIRED) gentoo-dev 2006-10-17 21:30:57 UTC
This is a one time only bug, because start-stop-deamon doesn't have information about the running apache. Do a manual stop (killall apache), zap the service (/etc/init.d/apache2 zap), then start it (/etc/init.d/apache2 start). After that you shouldn't have any issues.

Please let me know if this doesn't work for you.
Comment 2 Ilya Eremin 2006-10-18 09:19:17 UTC
I am stupid....
That worked fine, thanks a lot and sorry for bugging you. Keep up the great work.
Comment 3 Honza 2007-10-08 21:47:46 UTC
It's not one-time bug. The way /etc/init.d/apache2 is now written, start-stop-daemon (at least the one from baselayout-1.12.9-r2) will be unable to stop apache2 after every update of apache2 binary, which is not so often, but still not only one-time.

(Reason is start-stop-daemon will compare inode of current /usr/sbin/apache2 with all processes and find no match, because running apaches are refering to now deleted previous version)

It is true that sequence apache2ctl stop, /etc/init.d/apache2 zap, /etc/init.d/apache2 start will do correct restart, but it will still be better if /etc/init.d/apache2 restart really worked.