[英]Nginx understanding access log column
I understand all the column of this app's access log- IP, date, request, response code and... except the next column is what I don't understand (in the example below, 177, 4223, 4356).我了解此应用程序访问日志的所有列 - IP、日期、请求、响应代码和...除了下一列是我不了解的内容(在下面的示例中,177、4223、4356)。 What is this stands for?
这是什么意思?
66.249.65.159 - - [06/Nov/2014:19:10:38 +0600] "GET /news/53f8d72920ba2744fe873ebc.html HTTP/1.1" 404 177 "-" "Mozilla/5.0 (iPhone; CPU iPhone OS 6_0 like Mac OS X) AppleWebKit/536.26 (KHTML, like Gecko) Version/6.0 Mobile/10A5376e Safari/8536.25 (compatible; Googlebot/2.1; +http://www.google.com/bot.html)"
66.249.65.3 - - [06/Nov/2014:19:11:24 +0600] "GET /?q=%E0%A6%AB%E0%A6%BE%E0%A7%9F%E0%A6%BE%E0%A6%B0 HTTP/1.1" 200 4223 "-" "Mozilla/5.0 (compatible; Googlebot/2.1; +http://www.google.com/bot.html)"
66.249.65.62 - - [06/Nov/2014:19:12:14 +0600] "GET /?q=%E0%A6%A6%E0%A7%8B%E0%A7%9F%E0%A6%BE HTTP/1.1" 200 4356 "-" "Mozilla/5.0 (compatible; Googlebot/2.1; +http://www.google.com/bot.html)"
Edit: I've googled, but couldn't find any answer.编辑:我用谷歌搜索,但找不到任何答案。
The column after "Response Code" (ie status) is "Bytes Sent". “响应代码”(即状态)之后的列是“发送的字节数”。
The default log format in nginx is called "combined". nginx中的默认日志格式称为“组合”。 It is the equivalent to the following configuration.
它等同于以下配置。
# nginx.conf
http {
...
log_format combined '$remote_addr - $remote_user [$time_local] '
'"$request" $status $body_bytes_sent '
'"$http_referer" "$http_user_agent"';
...
}
In your given example, 在你给出的例子中,
177, 4223, 4356 indicates the number of bytes sent, excluding the HTTP headers. 177,4223,4356表示发送的字节数,不包括HTTP头。
Default logs provided by both Apache and NGINX are pretty much identical. Apache和NGINX提供的默认日志完全相同。 While the variable naming conventions differ, the information available is relatively the same.
虽然变量命名约定不同,但可用信息相对相同。
NGINX Logging Variables Documentation<\/a><\/strong> NGINX 记录变量文档<\/a><\/strong>
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.