apache2 中的自定义错误日志
Custom error log in apache2
在 apache 日志文件中,我收到很长的消息,例如:
[Wed Feb 21 19:32:18.916451 2018] [:error] [pid 23919] [client 10.0.2.2:50156] Error Message...
如何获取自定义日志消息,例如:
格式:[时间][留言]
[19:32:18] Error Message....
放
ErrorLogFormat "[%{c}t] %M"
在 apache 配置文件中(据说,/etc/apache2/apache2.conf)
您可以在 https://httpd.apache.org/docs/2.4/mod/core.html#errorlogformat
中找到其他格式设置选项
在 apache 日志文件中,我收到很长的消息,例如:
[Wed Feb 21 19:32:18.916451 2018] [:error] [pid 23919] [client 10.0.2.2:50156] Error Message...
如何获取自定义日志消息,例如:
格式:[时间][留言]
[19:32:18] Error Message....
放
ErrorLogFormat "[%{c}t] %M"
在 apache 配置文件中(据说,/etc/apache2/apache2.conf)
您可以在 https://httpd.apache.org/docs/2.4/mod/core.html#errorlogformat