proxy_http_version

Syntax: proxy_http_version 1.0 | 1.1; Default: proxy_http_version 1.0; Context: http, server, location This directive appeared in version 1.1.4. Sets the HTTP protocol version for proxying. By default, version 1.0 is used. Version 1.1 is recommended for use with keepalive connections and NTLM authentication.

How nginx processes a request

How nginx processes a request How to prevent processing requests with undefined server names Mixed name-based and IP-based virtual servers A simple PHP site configuration

limit_conn_zone

Syntax: limit_conn_zone key zone=name:size; Default: — Context: stream Sets parameters for a shared memory zone that will keep states for various keys. In particular, the state includes the current number of connections. The key can contain text, variables, and their combinations (1.11.2). Connections with an empty key value are not accounted. Usage example: limit_conn_zone $binary_remote_addr zone=addr:10m; Here, the key is a client IP address set by the $binary_remot

proxy_next_upstream_tries

Syntax: proxy_next_upstream_tries number; Default: proxy_next_upstream_tries 0; Context: http, server, location This directive appeared in version 1.7.5. Limits the number of possible tries for passing a request to the next server. The 0 value turns off this limitation.

keepalive_timeout

Syntax: keepalive_timeout timeout [header_timeout]; Default: keepalive_timeout 75s; Context: http, server, location The first parameter sets a timeout during which a keep-alive client connection will stay open on the server side. The zero value disables keep-alive client connections. The optional second parameter sets a value in the “Keep-Alive: timeout=time” response header field. Two parameters may differ. The “Keep-Alive: timeout=time” header field is recognized by Mo

secure_link

Syntax: secure_link expression; Default: — Context: http, server, location Defines a string with variables from which the checksum value and lifetime of a link will be extracted. Variables used in an expression are usually associated with a request; see example below. The checksum value extracted from the string is compared with the MD5 hash value of the expression defined by the secure_link_md5 directive. If the checksums are different, the $secure_link variable is set to an e

ssl_session_ticket_key

Syntax: ssl_session_ticket_key file; Default: — Context: stream, server Sets a file with the secret key used to encrypt and decrypt TLS session tickets. The directive is necessary if the same key has to be shared between multiple servers. By default, a randomly generated key is used. If several keys are specified, only the first key is used to encrypt TLS session tickets. This allows configuring key rotation, for example: ssl_session_ticket_key current.key; ssl_session_ticket_k

open_file_cache

Syntax: open_file_cache off;open_file_cache max=N [inactive=time]; Default: open_file_cache off; Context: http, server, location Configures a cache that can store: open file descriptors, their sizes and modification times; information on existence of directories; file lookup errors, such as “file not found”, “no read permission”, and so on. Caching of errors should be enabled separately by the open_file_cache_errors directive. The directive has the following parameters

Controlling nginx

Controlling nginx Changing Configuration Rotating Log-files Upgrading Executable on the Fly nginx can be controlled with signals. The process ID of the master process is written to the file /usr/local/nginx/logs/nginx.pid by default. This name may be changed at configuration time, or in nginx.conf using the pid directive. The master process supports the following signals: TERM, INT fast shutdown QUIT graceful shutdown HUP changing configuration, keeping up with a changed time zone (only for

scgi_next_upstream_timeout

Syntax: scgi_next_upstream_timeout time; Default: scgi_next_upstream_timeout 0; Context: http, server, location This directive appeared in version 1.7.5. Limits the time during which a request can be passed to the next server. The 0 value turns off this limitation.