Skip to content

Instantly share code, notes, and snippets.

@takashi
Created July 5, 2015 04:17
Show Gist options
  • Select an option

  • Save takashi/eb7ac830289eba168819 to your computer and use it in GitHub Desktop.

Select an option

Save takashi/eb7ac830289eba168819 to your computer and use it in GitHub Desktop.
lstv format for nginx

lstv format for nginx

access_log /var/log/access.log ltsv; error_log /var/log/error.log;

log_format ltsv 'time:$time_iso8601\t'
                  'remote_addr:$remote_addr\t'
                  'request_method:$request_method\t'
                  'request_length:$request_length\t'
                  'request_uri:$request_uri\t'
                  'https:$https\t'
                  'uri:$uri\t'
                  'query_string:$query_string\t'
                  'status:$status\t'
                  'bytes_sent:$bytes_sent\t'
                  'body_bytes_sent:$body_bytes_sent\t'
                  'referer:$http_referer\t'
                  'useragent:$http_user_agent\t'
                  'forwardedfor:$http_x_forwarded_for\t'
                  'request_time:$request_time\t'
                  'upstream_response_time:$upstream_response_time';
access_log /var/log/access.log ltsv;
error_log  /var/log/error.log ltsv;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment