From: Paul Querna Date: Thu, 16 Jun 2005 19:05:58 +0000 (+0000) Subject: - Add documentation on the new AcceptFilter directive. X-Git-Tag: 2.1.5~4 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=97220fc14f4c59f421cfddfce6aff016e2414857;p=apache - Add documentation on the new AcceptFilter directive. - Update Listen with the optional protocol arg. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@190982 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/docs/manual/mod/core.html.en b/docs/manual/mod/core.html.en index 613ccfbec0..262cfaed00 100644 --- a/docs/manual/mod/core.html.en +++ b/docs/manual/mod/core.html.en @@ -31,6 +31,7 @@ available

Directives

+
top
+

AcceptFilter Directive

+ + + + + + + +
Description:Configures optimizations for a Protocol's Listener Sockets
Syntax:AcceptFilter protocol accept_filter
Context:server config
Status:Core
Module:core
Compatibility:Available in Apache 2.1.5 and later
+

This directive enables operating system specific optimizations for a + listening socket by the Protocol type. The basic premise is for the + kernel to not send a socket to the server process until either data + is received or an entire HTTP Request is buffered. Only + + FreeBSD's Accept Filters and Linux's more primitive + TCP_DEFER_ACCEPT are currently supported.

+ +

The default values on FreeBSD are:

+

+ AcceptFilter http httpready
+ AcceptFilter https dataready +

+ +

The httpready accept filter buffers entire HTTP requests at + the kernel level. Once an entire request is recieved, the kernel then + sends it to the server. See the + + accf_http(9) man page for more details. Since HTTPS requests are + encrypted only the + accf_data(9) filter is used.

+ +

The default values on Linux are:

+

+ AcceptFilter http data
+ AcceptFilter https data +

+ +

Linux's TCP_DEFER_ACCEPT does not support buffering http + requests. Any value besides none will enable + TCP_DEFER_ACCEPT on that listener. For more details + see the Linux + + tcp(7) man page.

+ +

Using none for an argument will disable any accept filters + for that protocol. This is useful for protocols that require a server + send data first, such as nntp:

+

AcceptFilter nttp none

+ + +
top

AcceptPathInfo Directive

diff --git a/docs/manual/mod/core.xml b/docs/manual/mod/core.xml index 4a9eb1c63c..1573105376 100644 --- a/docs/manual/mod/core.xml +++ b/docs/manual/mod/core.xml @@ -27,6 +27,57 @@ availableCore + +AcceptFilter +Configures optimizations for a Protocol's Listener Sockets +AcceptFilter protocol accept_filter +server config +Available in Apache 2.1.5 and later + + +

This directive enables operating system specific optimizations for a + listening socket by the Protocol type. The basic premise is for the + kernel to not send a socket to the server process until either data + is received or an entire HTTP Request is buffered. Only + + FreeBSD's Accept Filters and Linux's more primitive + TCP_DEFER_ACCEPT are currently supported.

+ +

The default values on FreeBSD are:

+ + AcceptFilter http httpready
+ AcceptFilter https dataready +
+ +

The httpready accept filter buffers entire HTTP requests at + the kernel level. Once an entire request is recieved, the kernel then + sends it to the server. See the + + accf_http(9) man page for more details. Since HTTPS requests are + encrypted only the + accf_data(9) filter is used.

+ +

The default values on Linux are:

+ + AcceptFilter http data
+ AcceptFilter https data +
+ +

Linux's TCP_DEFER_ACCEPT does not support buffering http + requests. Any value besides none will enable + TCP_DEFER_ACCEPT on that listener. For more details + see the Linux + + tcp(7) man page.

+ +

Using none for an argument will disable any accept filters + for that protocol. This is useful for protocols that require a server + send data first, such as nntp:

+ AcceptFilter nttp none + +
+
+ AcceptPathInfo Resources accept trailing pathname information diff --git a/docs/manual/mod/directives.html.en b/docs/manual/mod/directives.html.en index 363b1fe056..5475d43294 100644 --- a/docs/manual/mod/directives.html.en +++ b/docs/manual/mod/directives.html.en @@ -41,7 +41,8 @@

 A  |  B  |  C  |  D  |  E  |  F  |  G  |  H  |  I  |  K  |  L  |  M  |  N  |  O  |  P  |  R  |  S  |  T  |  U  |  V  |  W  |  X 

- + - - + +
Description:IP addresses and ports that the server listens to
Syntax:Listen [IP-address:]portnumber
Syntax:Listen [IP-address:]portnumber [protocol]
Context:server config
Status:MPM
Module:beos, leader, mpm_netware, mpm_winnt, mpmt_os2, perchild, prefork, threadpool, worker
Compatibility:Required directive since Apache 2.0
Module:beos, leader, mpm_netware, mpm_winnt, mpmt_os2, perchild, prefork, threadpool, worker, event
Compatibility:Required directive since Apache 2.0
+The protocol argument was added in 2.1.5

The Listen directive instructs Apache to listen to only specific IP addresses or ports; by default it @@ -276,12 +277,27 @@ listens to Listen [fe80::a00:20ff:fea7:ccea]:80

+

The optional protocol argument is not required for most + configurations. If not specified, https is the default for + port 443 and http the default for all other ports. The + protocol is used to determine which module should handle a request, and + to apply protocol specific optimizations with the + AcceptFilter directive.

+ +

You only need to set the protocol if you are running on non-standard + ports. For example, running an https site on port 443:

+ +

+ Listen 192.170.2.1:8443 https +

+

Error condition

Multiple Listen directives for the same ip address and port will result in an Address already in use error message.
+

See also