Package: apache2.2-common
Version: 2.2.16-6+squeeze4
Severity: normal
Tags: patch
Dear Maintainer,
First of all, sorry for my poor English.
/etc/init.d/apache2 start is completed before apache2 is really
started.
And, /etc/init.d/apache2 restart is completed before apache2 is
really restarted.
For example, if /etc/init.d/apache2 start and /etc/init.d/apache2
status are run continuously, it will be displayed as Apache2 is NOT
running..
But, if /etc/init.d/apache2 status is run after several seconds, it
will be displayed as Apache2 is running (pid )..
# ps -ef | grep -v grep | grep apache
root 2603 1 0 05:51 ?00:00:00 /usr/sbin/apache2 -k start
www-data 2610 2603 0 05:51 ?00:00:00 /usr/sbin/apache2 -k start
www-data 2611 2603 0 05:51 ?00:00:00 /usr/sbin/apache2 -k start
www-data 2612 2603 0 05:51 ?00:00:00 /usr/sbin/apache2 -k start
www-data 2613 2603 0 05:51 ?00:00:00 /usr/sbin/apache2 -k start
www-data 2614 2603 0 05:51 ?00:00:00 /usr/sbin/apache2 -k start
# /etc/init.d/apache2 stop
Stopping web server: apache2 ... waiting .
# ps -ef | grep -v grep | grep apache
# /etc/init.d/apache2 start ; echo $? ; /etc/init.d/apache2 status ; echo $?
Starting web server: apache2.
0
Apache2 is NOT running.
3
# /etc/init.d/apache2 status ; echo $?
Apache2 is running (pid 2929).
0
And if /etc/init.d/apache2 restart and /etc/init.d/apache2 status
are run continuously, it will be displayed as Apache2 is NOT running..
But, if /etc/init.d/apache2 status is run after several seconds, it
will be displayed as Apache2 is running (pid )..
# ps -ef | grep -v grep | grep apache
root 2929 1 0 05:57 ?00:00:00 /usr/sbin/apache2 -k start
www-data 2940 2929 0 05:57 ?00:00:00 /usr/sbin/apache2 -k start
www-data 2941 2929 0 05:57 ?00:00:00 /usr/sbin/apache2 -k start
www-data 2942 2929 0 05:57 ?00:00:00 /usr/sbin/apache2 -k start
www-data 2943 2929 0 05:57 ?00:00:00 /usr/sbin/apache2 -k start
www-data 2944 2929 0 05:57 ?00:00:00 /usr/sbin/apache2 -k start
# /etc/init.d/apache2 restart ; echo $? ; /etc/init.d/apache2 status ; echo $?
Restarting web server: apache2 ... waiting .
0
Apache2 is NOT running.
3
# /etc/init.d/apache2 status ; echo $?
Apache2 is running (pid 2987).
0
This symptom has a bad influence on operation of HA cluster resource
manager (such as pacemaker).
The attached patch corrects /etc/init.d/apache2 so that it waits for
apache2 to be really started or restarted.
Please review the attached patch, and if satisfactory, consider
including it in the package.
P.S.
It seems that this symptom does not occur when the load of apache is
low to some extent.
In our system, when some modules (such as perl, php5 and python) were
enabled, the above-mentioned symptom occurred.
But, when some modules (such as perl, php5 and python) were disabled,
even if I ran /etc/init.d/apache2 start and /etc/init.d/apache2
status continuously, it came to be immediately displayed as Apache2
is running (pid )..
Thanks,
-- Package-specific info:
List of enabled modules from 'apache2 -M':
alias auth_basic authn_file authz_default authz_groupfile
authz_host authz_user autoindex cgi deflate dir env mime
negotiation perl php5 python reqtimeout setenvif status
List of enabled php5 extensions:
pdo
-- System Information:
Debian Release: 6.0.3
APT prefers stable-updates
APT policy: (500, 'stable-updates'), (500, 'stable')
Architecture: i386 (i686)
Kernel: Linux 2.6.32-5-686 (SMP w/1 CPU core)
Locale: LANG=ja_JP.UTF-8, LC_CTYPE=ja_JP.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Versions of packages apache2.2-common depends on:
ii apache2-utils 2.2.16-6+squeeze4 utility programs for webservers
ii apache2.2-bin 2.2.16-6+squeeze4 Apache HTTP Server common binary f
ii libmagic1 5.04-5File type determination library us
ii lsb-base 3.2-23.2squeeze1 Linux Standard Base 3.2 init scrip
ii mime-support 3.48-1MIME files 'mime.types' 'mailcap
ii perl 5.10.1-17squeeze2 Larry Wall's Practical Extraction
ii procps 1:3.2.8-9 /proc file system utilities
Versions of packages apache2.2-common recommends:
ii ssl-cert 1.0.28 simple debconf wrapper for OpenSSL
Versions of packages apache2.2-common suggests:
pn apache2-doc none (no description available)
pn apache2-suexec | apache2-suex none (no description available)
ii w3m [www-browser] 0.5.2-9WWW browsable pager with excellent
Versions of packages apache2.2-common is related to:
pn apache2-mpm-event none(no description available)
pn apache2-mpm-itknone(no description available)
ii apache2-mpm-prefork2.2.16-6+squeeze4 Apache HTTP Server - traditional n
pn apache2-mpm-worker none