Bug 37863 - kill -1 httpd_id -> Failed to enable the 'httpready' Accept Filter
Summary: kill -1 httpd_id -> Failed to enable the 'httpready' Accept Filter
Status: CLOSED FIXED
Alias: None
Product: APR
Classification: Unclassified
Component: APR (show other bugs)
Version: 1.4.6
Hardware: PC FreeBSD
: P1 major with 11 votes (vote)
Target Milestone: ---
Assignee: Apache Portable Runtime bugs mailinglist
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-12-11 01:16 UTC by Claudio Eichenberger
Modified: 2014-02-17 13:46 UTC (History)
4 users (show)



Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Claudio Eichenberger 2005-12-11 01:16:29 UTC
The httpd starts and works nicely on a amd64, 2 dual-Opteron processor box, 
FreeBSD 6.0, kernel compiled with 'options ACCEPT_FILTER_HTTP'.

But a kill -1 on the httpd root pid writes the following lines to the log file:

[Sun Dec 11 00:01:19 2005] [notice] SIGHUP received.  Attempting to restart
[Sun Dec 11 00:01:19 2005] [warn] (22)Invalid argument: Failed to enable the 
'httpready' Accept Filter
[Sun Dec 11 00:01:19 2005] [warn] (22)Invalid argument: Failed to enable the 
'httpready' Accept Filter
[Sun Dec 11 00:01:19 2005] [notice] Apache configured -- resuming normal 
operations

I can provoke the message with a minimal configuration of only the following 
module: LoadModule log_config_module modules/mod_log_config.so

Compiled in modules:
  core.c
  prefork.c
  http_core.c
  mod_so.c
Comment 1 Paul Querna 2005-12-11 01:20:06 UTC
you only get this warning on restart, not on startup?
Comment 2 Claudio Eichenberger 2005-12-11 01:29:20 UTC
Yes, only on restart.
Comment 3 Paul Querna 2005-12-11 22:30:47 UTC
Okay, I can repo it here.

We need to pass the fact that we are currently doing a restart, down to the code
in server/listen.c.  Not an easy way right now.
Comment 4 Victor Engmark 2007-04-12 07:11:20 UTC
Still an issue with Apache/2.2.4 and php5-5.2.1_3.
Comment 5 toomas.aas 2007-11-28 02:07:32 UTC
I still see this with Apache 2.2.6 on FreeBSD 7.0-BETA3
Comment 6 Walter Hop 2008-08-13 06:31:18 UTC
I can confirm that this issue still seems to exist with Apache/2.2.9, FreeBSD 7.0-RELEASE-p3 on i386.

On "apachectl start" and "apachectl stop; apachectl start" there is no warning. However, "apachectl restart" and similarly "apachectl graceful" predictably produce the warning.

[Wed Aug 13 15:30:28 2008] [notice] SIGHUP received.  Attempting to restart
[Wed Aug 13 15:30:28 2008] [warn] (22)Invalid argument: Failed to enable the 'httpready' Accept Filter
[Wed Aug 13 15:30:28 2008] [warn] (22)Invalid argument: Failed to enable the 'httpready' Accept Filter

Comment 7 rahul 2008-08-26 04:51:54 UTC
Confirming this in trunk, and also on startup.
I also see a file called accept.lock.<pid> under logs i.e logs/accept.lock.95338

|uname -a
FreeBSD vayavyam.India.Sun.COM 6.1-RELEASE FreeBSD 6.1-RELEASE #0: Sun May  7 04:32:43 UTC 2006     root@opus.cse.buffalo.edu:/usr/obj/usr/src/sys/GENERIC  i386
|ls logs 
accept.lock.95338       access_log              error_log               httpd.pid
|cat logs/httpd.pid 
95338
|./bin/apachectl start
[Tue Aug 26 17:05:29 2008] [warn] (2)No such file or directory: Failed to enable the 'httpready' Accept Filter
|cat logs/error_log 
[Tue Aug 26 17:05:29 2008] [debug] proxy_util.c(1851): proxy: grabbed scoreboard slot 0 in child 95362 for worker proxy:reverse
[Tue Aug 26 17:05:29 2008] [debug] proxy_util.c(1966): proxy: initialized single connection worker 0 in child 95362 for (*)
[Tue Aug 26 17:05:29 2008] [debug] proxy_util.c(1851): proxy: grabbed scoreboard slot 0 in child 95363 for worker proxy:reverse
[Tue Aug 26 17:05:29 2008] [debug] proxy_util.c(1869): proxy: worker proxy:reverse already initialized
[Tue Aug 26 17:05:29 2008] [debug] proxy_util.c(1966): proxy: initialized single connection worker 0 in child 95363 for (*)
[Tue Aug 26 17:05:29 2008] [notice] Apache/2.3.0-dev (Unix) configured -- resuming normal operations
[Tue Aug 26 17:05:29 2008] [info] Server built: Aug 26 2008 16:53:07
[Tue Aug 26 17:05:29 2008] [debug] prefork.c(960): AcceptMutex: flock (default: flock)
[Tue Aug 26 17:05:29 2008] [debug] proxy_util.c(1851): proxy: grabbed scoreboard slot 0 in child 95364 for worker proxy:reverse
[Tue Aug 26 17:05:29 2008] [debug] proxy_util.c(1869): proxy: worker proxy:reverse already initialized
[Tue Aug 26 17:05:29 2008] [debug] proxy_util.c(1966): proxy: initialized single connection worker 0 in child 95364 for (*)
[Tue Aug 26 17:05:29 2008] [debug] proxy_util.c(1851): proxy: grabbed scoreboard slot 0 in child 95365 for worker proxy:reverse
[Tue Aug 26 17:05:29 2008] [debug] proxy_util.c(1869): proxy: worker proxy:reverse already initialized
[Tue Aug 26 17:05:29 2008] [debug] proxy_util.c(1966): proxy: initialized single connection worker 0 in child 95365 for (*)
[Tue Aug 26 17:05:29 2008] [debug] proxy_util.c(1851): proxy: grabbed scoreboard slot 0 in child 95366 for worker proxy:reverse
[Tue Aug 26 17:05:29 2008] [debug] proxy_util.c(1869): proxy: worker proxy:reverse already initialized
[Tue Aug 26 17:05:29 2008] [debug] proxy_util.c(1966): proxy: initialized single connection worker 0 in child 95366 for (*)

Comment 8 Philp M. Gollucci 2009-01-18 16:19:12 UTC
CC myself on FreeBSD related bugs
Comment 9 Nick Kew 2009-12-20 17:15:53 UTC
apr/
Comment 10 Nick Kew 2009-12-20 17:17:53 UTC
sorry, last comment was mouse trouble; ignore.
Comment 11 Daniel 2010-04-15 11:42:02 UTC
I got this issue too in FreeBSD 8.0-RELEASE-p2
Comment 12 Andrey Chernov 2010-07-20 07:06:35 UTC
Still an issue with Apache/2.2.15 on FreeBSD 9.0-CURRENT i386
Comment 13 Daniel 2010-07-20 07:37:09 UTC
maybe time someone fixes a bug thats 5 years old?

I have this problem too with the setup stated below and it sucks balls to have to make a hard restart everytime
FreeBSD 8.0-RELEASE-p4 
Server version: Apache/2.2.15 (FreeBSD)
Server built:   Jul 18 2010 20:54:26
Comment 14 Rustam Abdullaev 2010-07-20 07:57:41 UTC
According to the code it looks like the error can be ignored; the ACCEPT_FILTER remains enabled during a "kill -1", that's why it can't be enabled again. Is that not the case?
Comment 15 Daniel 2010-07-20 07:59:36 UTC
Nope, the httpd completly dies when this happens and you have to start it again
Comment 16 Jeff Trawick 2012-11-07 15:52:49 UTC
>Nope, the httpd completly dies when this happens and you have to start it again

I can't reproduce the issue of httpd exiting with 2.2.15, 2.2.latest, or trunk on FreeBSD 9 RELEASE.  That seems to be a different issue, as there hasn't been logic to trigger an error based on a failure to set the accept filter.
Comment 17 Jeff Trawick 2012-11-07 16:14:27 UTC
Fixed in apr trunk r1406690...
Fixed in apr 1.5.x r1406693...
Fixed in apr 1.4.x r1406694...