is starting up in FreeBSD system, Apache loads succcessfully and web server functioning properly, but the following warning error occurs:
[warn] (2)No such file or directory:
Failed to enable the ‘httpready’ Accept Filter
The resolution to the above problem is to a accf_http module, which function is to buffer incoming connections until a certain complete HTTP requests arrive, into FreeBSD kernel by using kernel linker:
kldload accf_http
To permanently load enable HTTP Accept Filter FreeBSD kernel module (accf_http), add the following line into /boot/loader.conf:
accf_http_load=”YES”
Note: The default settings is located in /boot/defaults/loader.cnf. To see the related settings about accf, use:
grep accf /boot/defaults/loader.conf
which will returns:
accf_data_load=”NO” # Wait for data accept filter
accf_http_load=”NO” # Wait for full HTTP request accept filter
============ [START] httpready accept filter problem solution ==============
Note: rc.d script for apache now manage this accf_http kernel module
Just add following line to your /etc/rc.conf
root@bmw0 [/root] # vi /etc/rc.conf
apache22_http_accept_enable="YES"
Please note that there is a line in httpd.conf:
Include etc/apache22/Includes/*.conf
the line above includes one of files called:
/usr/local/etc/apache22/Includes/no-accf.conf
This file above turns accf_http off.
So, make sure you do comment out two lines in /usr/local/etc/apache22/Includes/no-accf.conf:
<IfDefine NOHTTPACCEPT>
#AcceptFilter http none
#AcceptFilter https none
</IfDefine>
============ [END] httpready accept filter problem solution ==============Adding to /boot/loader.conf will make the change permanent, but if you fancy testing this change out without rebooting your system, you can run this: -
# kldload accf_http
You can see that it’s been loaded by doing: -
# kldstat
Id Refs Address Size Name
1 5 0xc0400000 6f6544 kernel
2 1 0xc41f6000 2000 accf_http.ko <-- you just loaded this module!
You can now restart Apache and see that your previous error is no longer.
No comments:
Post a Comment