使用goaccess的nginx日志分析没有可处理的有效内容



我想分析我的Web服务器日志,但我在goaccess(0.9.6版本)中遇到了这个错误:

没有可处理的有效内容。验证您的日期/时间/日志格式。

我的nginx配置如下:

$remote_addr - $remote_user [$time_local] $host "$request" $status $bytes_sent "$http_referer" "$http_user_agent" "$gzip_ratio" $request_time Sek

我的nginx日志如下:

151.80.xx.xx - - [08/Dec/2015:15:38:35 +0100] domain.com "GET /h/haval2245/000f86240fa9e09c95a6a88b36474be86d39c774a074da1f5dd244b6 HTTP/1.1" 200 3123 "-" "Mozilla/5.0 (compatible; AhrefsBot/5.0; +http: //ahrefs.com/robot/)" "2.50" 0.063 Sek
194.166.xx.xx - - [08/Dec/2015:15:38:37 +0100] domain.com "GET /api/user.php?apikey=2 HTTP/1.1" 301 428 "-" "JDownloader" "-" 0.000 Sek
194.166.xx.xx - - [08/Dec/2015:15:38:38 +0100] www.domain.com "GET /api/user.php?apikey=2 HTTP/1.1" 200 695 "-" "JDownloader" "1.42" 0.002 Sek
194.166.xx.xx - - [08/Dec/2015:15:38:38 +0100] www.domain.com "GET /api/hosts.php?online=1 HTTP/1.1" 200 797 "http: //www.domain.com/api/user.php?apikey=2" "JDownloader" "3.57" 0.001 Sek
194.154.xx.xx - - [08/Dec/2015:15:38:40 +0100] domain.me "POST /index.php?liveupdate HTTP/2.0" 200 440 "https: //domain.me/pages/download/" "Mozilla/5.0 (Windows NT 6.1; WOW64; rv:42.0) Gecko/20100101 Firefox/42.0" "1.06" 0.052 Sek
202.238.xx.xx - - [08/Dec/2015:15:38:44 +0100] domain.me "GET / HTTP/1.1" 301 366 "-" "Mozilla/5.0 (Windows NT 6.3; WOW64; rv:40.0) Gecko/20100101 Firefox/40.0" "-" 0.000 Sek
202.238.xx.xx - - [08/Dec/2015:15:38:45 +0100] domain.me "GET / HTTP/1.1" 200 10945 "-" "Mozilla/5.0 (Windows NT 6.3; WOW64; rv:40.0) Gecko/20100101 Firefox/40.0" "-" 0.231 Sek
202.238.xx.xx - - [08/Dec/2015:15:38:46 +0100] domain.me "GET /favicon.ico HTTP/1.1" 301 377 "-" "Mozilla/5.0 (Windows NT 6.3; WOW64; rv:40.0) Gecko/20100101 Firefox/40.0" "-" 0.000 Sek
91.0.xx.xx - - [08/Dec/2015:15:38:50 +0100] www.domain.com "GET /api/v2/user.php?SPSTORE HTTP/1.1" 200 876 "-" "domain.exe - 4.0" "-" 0.001 Sek
77.1.xx.xx - - [08/Dec/2015:15:38:51 +0100] domain.me "POST /index.php?liveupdate HTTP/2.0" 200 442 "https: //domain.me/threads/die-grosse-adventslotterie.452/page-5" "Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2490.86 Safari/537.36" "1.04" 0.070 Sek

这是我的goaccess选项:

time-format %H:%M:%S
date-format %d/%b/%Y
log-format %r - %^ [%d:%t %^] %^ "%r" %s %b "%R" "%u" "%^" %^ %^

以下适用于您的日志格式:

log-format %h %^[%d:%t %^] %v "%r" %s %b "%R" "%u" %^ %T %^
time-format %H:%M:%S
date-format %d/%b/%Y

相关内容

  • 没有找到相关文章

最新更新