# HG changeset patch # User Ruslan Ermilov # Date 1318178132 0 # Node ID 9332d7a02822b4b6e9068b812888adc279c5fce7 # Parent f122a777a6de7d27453faf3dbe634564318bcb17 In the "listen" directive, - the "default" parameter was deprecated in favour of "default_server", - an ability to specify additional parameters no longer depends on "default", - there's a "setfib" parameter on FreeBSD, - UNIX-domain sockets are supported. diff -r f122a777a6de -r 9332d7a02822 xml/en/docs/http/ngx_http_core_module.xml --- a/xml/en/docs/http/ngx_http_core_module.xml Sun Oct 09 14:43:46 2011 +0000 +++ b/xml/en/docs/http/ngx_http_core_module.xml Sun Oct 09 16:35:32 2011 +0000 @@ -772,7 +772,21 @@ listen address[:port] - [default | default_server + [default_server] + [setfib=number] + [backlog=number] + [rcvbuf=size] + [sndbuf=size] + [accept_filter=filter] + [deferred] + [bind] + [ipv6only=on|off] + [ssl] + +listen + port + [default_server] + [setfib=number] [backlog=number] [rcvbuf=size] [sndbuf=size] @@ -780,27 +794,27 @@ [deferred] [bind] [ipv6only=on|off] - [ssl]] + [ssl] listen - port - [default | default_server + unix:path + [default_server] [backlog=number] [rcvbuf=size] [sndbuf=size] [accept_filter=filter] [deferred] [bind] - [ipv6only=on|off] - [ssl]] + [ssl] listen *:80 | *:8000 server -Sets an address and a port, on which +Sets an address and a port for IP, +or a path for a UNIX-domain socket, on which the server will accept requests. -Only one of address or port can be +Only one of address or port may be specified. An address may also be a hostname, for example: @@ -815,6 +829,10 @@ listen [::]:8000; listen [fe80::1]; +UNIX-domain sockets (0.8.21) are specified with the “unix:” prefix: + +listen unix:/var/run/nginx.sock; + @@ -827,28 +845,43 @@ -The default parameter, if present, +The default_server parameter, if present, will cause the server to become the default server for the specified address:port pair. -If none of the directives have the default +If none of the directives have the default_server parameter then the first server with the address:port pair will be the default server for this pair. -Starting from version 0.8.21 it is possible to use the -default_server -parameter. + +In versions prior to 0.8.21 this parameter is named simply +default. + -A listen directive which has the default -parameter can have several additional parameters specific to system calls +A listen directive +can have several additional parameters specific to system calls listen and bind. -Starting from version 0.8.21, these parameters can be specified in any +They can be specified in any listen directive, but only once for the given address:port pair. + +In versions prior to 0.8.21, they could only be +specified in the listen directive with the +default parameter. + +setfib=number + + +this parameter (0.8.44) sets the associated FIB (routing table) +for the listening socket. +This currently works only on FreeBSD. + + + backlog=number