请查找我的nginx(access.log)
的日志输出182.69.143.120 - - [31 / Mar / 2016:03:10:51 +0530]" GET /api/check_delivery.php?authkey=9450AW2qTKYe453be757c&requestid=36626f6a3530323439383831 HTTP / 1.1" control.msg91.com 404 39" - " " - " " - " " control.msg91.com" " - "至:10.0.0.62:8080:upstream_response_time 0.003 request_time 0.003
我的nginx自定义日志格式:
$ remote_addr - $ remote_user [$ time_local]" $ request" $主机' ' $ status $ body_bytes_sent" $ http_referer" ' '" $ HTTP_USER_AGENT" " $ HTTP_X_FORWARDED_FOR" " $服务器名"&#39 ;;
以及我在goaccess conf文件中使用的内容:
时间格式%H:%M:%S
日期格式%d /%b /%Y
log_format%^ [%d:%^]"%r" %s%b"%R" "%U" "%^%h"
在运行此操作后,我收到以下错误:
GoAccess - 0.9.8版 - 2016年3月31日14:11:22 配置文件:/usr/local/etc/goaccess.conf
发生了致命错误 发生错误:src / goaccess.c - main - 1017 无需处理任何内容。验证您的日期/时间/日志格式。
请帮帮我... 提前谢谢
答案 0 :(得分:3)
尝试使用以下日志格式:
log-format %h %^[%d:%t %^] "%r" %s %b "%R" "%u"