Nginx built log variables Detailed

Parameter value $ args # request
$ query_string # args with $
$ arg_NAME #get request NAME value
$ is_args # If there is a request parameter value "?", otherwise empty string
current request $ uri # URI (with no request parameters parameters are in the $ args), the browser may be different from the value of the $ REQUEST_URI transmission, which can be internal redirect, modify or use index instruction, $ URI does not contain a host name, such as "/ foo /bar.html ".
$ document_uri # with $ uri
$ DOCUMENT_ROOT # document root directory or alias for the current request
$ host # priority: HTTP request hostname line> "HOST" request header field> in line with the server name requested host header field in the request. If the host header in the request is not available, for the server processes the request of the server name
$ hostname # hostname
$ https # If you turn SSL security mode is "on", otherwise empty string.
$ binary_remote_addr # binary form of the address of the client, a fixed length of 4 bytes
$ body_bytes_sent # number of bytes transmitted to the client, the response headers are not counted; mod_log_config this variable and Apache module "
$ bytes_sent # transmitted to the client of bytes
sequence number $ connection #TCP connected
$ connection_requests #TCP connected to the current number of requests
$ content_length # "Content-Length" header field in the request
$ content_type # "Content-Type" header field in the request
$ cookie_name #cookie name
$ limit_rate # response for setting the speed limit is
$ msec # current Unix timestamp
$ nginx_version #nginx version
$ pid # work process PID
$ pipe # If the request from the pipe communication, the value of "p", otherwise is. ""
$ # proxy_protocol_addr get access to the proxy server address of the client, if it is a direct access, the value is an empty string
true path to the document root directory or alias $ realpath_root # the current request, all symbolic links will be converted to real path
$ remote_addr # client address
$ remote_port # client port
$ remote_user # for HTTP basic authentication service username
request address $ request # behalf of the client
$ request_body # client request body: This variable can be used in location, the body of the request by the next proxy_pass, fastcgi_pass, uwsgi_pass and scgi_pass passed to a proxy server
$ request_body_file # client request body is stored in a temporary file. After the file handle, the file to be deleted. If one needs to turn this feature on, you need to set client_body_in_file_only. If the file transfer times to the back-end proxy server, you need to disable the request body, that is set OFF proxy_pass_request_body, fastcgi_pass_request_body OFF, OFF uwsgi_pass_request_body, or scgi_pass_request_body OFF
$ request_completion # If the request succeeds, a value of "OK", if the request is not completed or the request is not the last part of a range request or a null
file path $ request_filename # current connection request, or a request by the root URI to the alias command generating
length $ request_length # requests (including the address of the request, and the request body of HTTP request header)
$ REQUEST_METHOD #HTTP request method, is generally "GET" or "POST"
$ request_time # client request use of the time, in seconds, milliseconds accuracy; starting from the first byte read client, until the last character to be transmitted until the client after the write log.
$ request_uri # this variable is equal to contain some of the original client request URI parameters, it can not be modified, please see the $ uri URI change or rewrite, does not include the host name, for example: "? / cnphp / test.php freemouse Arg ="
$ scheme # requests a Web protocol used, "http" or "HTTPS"
$ # server_addr server address, should be noted that: in order to avoid access linux kernel, ip address should be set in the configuration file in advance
$ server_name # server name
$ server_port # server port
$ server_protocol # server HTTP version, is generally "HTTP / 1.0" or "HTTP / 1.1"
$ #http Status response Code
ISO 8610 format server time $ time_iso8601 #
$ time_local # server time (LOG format format)
$ cookie_NAME # cookie client request header header variable, the prefix "$ cookie_" plus the name of the cookie variable, the variable's value is the value of the cookie name
$ http_NAME # matches any request header field; NAME latter part of the variable name can be replaced with any request header fields, such as the need to obtain the http request in the configuration file header: "Accept-Language", $ http_accept_language to
$ HTTP_COOKIE
$ HTTP_HOST # request address, the browser address you entered (IP or domain name)
$ HTTP_REFERER #URL jump source, used to record the access link from that page over
$ http_user_agent # user terminal browser and other information
$ HTTP_X_FORWARDED_FOR
$ # can sent_http_NAME set any http response header field; nAME latter part of the variable name can be replaced with any response header field, such as the need to set the response header Content-length, $ sent_http_content_length to
$ sent_http_cache_control
$ sent_http_connection
$ sent_http_content_type
$ sent_http_keep_alive
$ sent_http_last_modified
$ sent_http_location
$ sent_http_transfer_encoding
 

Guess you like

Origin blog.csdn.net/qq_42409788/article/details/84068125