| The PostgreSQL 9.0 Reference Manual - Volume 3 - Server Administration Guide
by The PostgreSQL Global Development Group Paperback (6"x9"), 274 pages ISBN 9781906966072 RRP £9.95 ($14.95) Sales of this book support the PostgreSQL project! Get a printed copy>>> |
4.3.1 Connection Settings
listen_addresses(string)-
Specifies the TCP/IP address(es) on which the server is
to listen for connections from client applications.
The value takes the form of a comma-separated list of host names
and/or numeric IP addresses. The special entry
*corresponds to all available IP interfaces. If the list is empty, the server does not listen on any IP interface at all, in which case only Unix-domain sockets can be used to connect to it. The default value islocalhost, which allows only local TCP/IP “loopback” connections to be made. While client authentication (section 5 Client Authentication) allows fine-grained control over who can access the server,listen_addressescontrols which interfaces accept connection attempts, which can help prevent repeated malicious connection requests on insecure network interfaces. This parameter can only be set at server start. port(integer)- The TCP port the server listens on; 5432 by default. Note that the same port number is used for all IP addresses the server listens on. This parameter can only be set at server start.
max_connections(integer)-
Determines the maximum number of concurrent connections to the
database server. The default is typically 100 connections, but
might be less if your kernel settings will not support it (as
determined during initdb). This parameter can
only be set at server start.
Increasing this parameter might cause PostgreSQL
to request more
System Vshared memory or semaphores than your operating system's default configuration allows. See section 3.4.1 Shared Memory and Semaphores for information on how to adjust those parameters, if necessary. When running a standby server, you must set this parameter to the same or higher value than on the master server. Otherwise, queries will not be allowed in the standby server. superuser_reserved_connections(integer)-
Determines the number of connection “slots” that
are reserved for connections by PostgreSQL
superusers. At most
max_connectionsconnections can ever be active simultaneously. Whenever the number of active concurrent connections is at leastmax_connectionsminussuperuser_reserved_connections, new connections will be accepted only for superusers, and no new replication connections will be accepted. The default value is three connections. The value must be less than the value ofmax_connections. This parameter can only be set at server start. unix_socket_directory(string)-
Specifies the directory of the Unix-domain socket on which the
server is to listen for
connections from client applications. The default is normally
‘/tmp’, but can be changed at build time.
This parameter can only be set at server start.
In addition to the socket file itself, which is named
.s.PGSQL.nnnnwhere nnnn is the server's port number, an ordinary file named.s.PGSQL.nnnn.lockwill be created in theunix_socket_directorydirectory. Neither file should ever be removed manually. This parameter is irrelevant on Windows, which does not have Unix-domain sockets. unix_socket_group(string)-
Sets the owning group of the Unix-domain socket. (The owning
user of the socket is always the user that starts the
server.) In combination with the parameter
unix_socket_permissionsthis can be used as an additional access control mechanism for Unix-domain connections. By default this is the empty string, which uses the default group of the server user. This parameter can only be set at server start. This parameter is irrelevant on Windows, which does not have Unix-domain sockets. unix_socket_permissions(integer)-
Sets the access permissions of the Unix-domain socket. Unix-domain
sockets use the usual Unix file system permission set.
The parameter value is expected to be a numeric mode
specified in the format accepted by the
chmodandumasksystem calls. (To use the customary octal format the number must start with a0(zero).) The default permissions are0777, meaning anyone can connect. Reasonable alternatives are0770(only user and group, see alsounix_socket_group) and0700(only user). (Note that for a Unix-domain socket, only write permission matters, so there is no point in setting or revoking read or execute permissions.) This access control mechanism is independent of the one described in section 5 Client Authentication. This parameter can only be set at server start. This parameter is irrelevant on Windows, which does not have Unix-domain sockets. bonjour(boolean)- Enables advertising the server's existence via Bonjour. The default is off. This parameter can only be set at server start.
bonjour_name(string)-
Specifies the Bonjour service
name. The computer name is used if this parameter is set to the
empty string
''(which is the default). This parameter is ignored if the server was not compiled with Bonjour support. This parameter can only be set at server start. tcp_keepalives_idle(integer)-
Specifies the number of seconds before sending a keepalive packet on
an otherwise idle connection. A value of 0 uses the system default.
This parameter is supported only on systems that support the
TCP_KEEPIDLEorTCP_KEEPALIVEsymbols, and on Windows; on other systems, it must be zero. This parameter is ignored for connections made via a Unix-domain socket.Note: On Windows, a value of 0 will set this parameter to 2 hours, since Windows does not provide a way to read the system default value.
tcp_keepalives_interval(integer)-
Specifies the number of seconds between sending keepalives on an
otherwise idle connection. A value of 0 uses the system default.
This parameter is supported only on systems that support the
TCP_KEEPINTVLsymbol, and on Windows; on other systems, it must be zero. This parameter is ignored for connections made via a Unix-domain socket.Note: On Windows, a value of 0 will set this parameter to 1 second, since Windows does not provide a way to read the system default value.
tcp_keepalives_count(integer)-
Specifies the number of keepalive packets to send on an otherwise idle
connection. A value of 0 uses the system default. This parameter is
supported only on systems that support the
TCP_KEEPCNTsymbol; on other systems, it must be zero. This parameter is ignored for connections made via a Unix-domain socket.Note: This parameter is not supported on Windows, and must be zero.
| ISBN 9781906966072 | The PostgreSQL 9.0 Reference Manual - Volume 3 - Server Administration Guide | See the print edition |