From c5011ca82e4c6bb32364914da865f917aa357755 Mon Sep 17 00:00:00 2001 From: Willy Tarreau Date: Mon, 22 Mar 2010 11:53:56 +0100 Subject: [PATCH] [DOC] indicate in the doc how to bind to port ranges This part was missing from the new doc. --- doc/configuration.txt | 36 ++++++++++++++++++++++++++---------- 1 file changed, 26 insertions(+), 10 deletions(-) diff --git a/doc/configuration.txt b/doc/configuration.txt index 9dff44acf..a2046ebbf 100644 --- a/doc/configuration.txt +++ b/doc/configuration.txt @@ -1239,13 +1239,13 @@ balance url_param [check_post []] "http_proxy". -bind [
]: [, ...] -bind [
]: [, ...] interface -bind [
]: [, ...] mss -bind [
]: [, ...] transparent -bind [
]: [, ...] id -bind [
]: [, ...] name -bind [
]: [, ...] defer-accept +bind [
]: [, ...] +bind [
]: [, ...] interface +bind [
]: [, ...] mss +bind [
]: [, ...] transparent +bind [
]: [, ...] id +bind [
]: [, ...] name +bind [
]: [, ...] defer-accept Define one or several listening addresses and/or ports in a frontend. May be used in sections : defaults | frontend | listen | backend no | yes | yes | no @@ -1256,9 +1256,25 @@ bind [
]: [, ...] defer-accept listened on. The same will apply for '*' or the system's special address "0.0.0.0". - is the TCP port number the proxy will listen on. The port is - mandatory. Note that in the case of an IPv6 address, the port - is always the number after the last colon (':'). + is either a unique TCP port, or a port range for which the + proxy will accept connections for the IP address specified + above. The port is mandatory. Note that in the case of an + IPv6 address, the port is always the number after the last + colon (':'). A range can either be : + - a numerical port (ex: '80') + - a dash-delimited ports range explicitly stating the lower + and upper bounds (ex: '2000-2100') which are included in + the range. + + Particular care must be taken against port ranges, because + every couple consumes one socket (= a file + descriptor), so it's easy to consume lots of descriptors + with a simple range, and to run out of sockets. Also, each + couple must be used only once among all + instances running on a same system. Please note that binding + to ports lower than 1024 generally require particular + privileges to start the program, which are independant of + the 'uid' parameter. is an optional physical interface name. This is currently only supported on Linux. The interface must be a physical