Hello Folks, How can we remove request url being logged in nginx error logs. For example it looks something like:
2015/09/01 15:26:03 [error] 30547#0: *208725 upstream prematurely closed connection while reading response header from upstream, client: 123.123.50.44, server: test.example.com, request: "GET /v1.3/status.json?...." is it possible to drop request from the log(if present) so it looks something like: 2015/09/01 15:26:03 [error] 30547#0: *208725 upstream prematurely closed connection while reading response header from upstream, client: 123.123.50.44, server: test.example.com I was able to configure access logs but couldn't find a way to customize error logs. If there is no way to drop just request, is it possible to drop complete error logs matching a particular format something similar to what https://github.com/cfsego/ngx_log_if does for access logs. I see that error_log is part of nginx core https://github.com/cfsego/ngx_log_if/blob/master/ngx_http_aclog_bypass_module.c, but would it be possible to extend by creating a new nginx module. I am really sorry since I am new to nginx code/module and this might sound stupid. Any suggestion/direction to achieve this is really appreciated. -- Thanks & Regards, Gaurav Gupta 7676-999-350 "Quality is never an accident. It is always result of intelligent effort" - John Ruskin
_______________________________________________ nginx mailing list nginx@nginx.org http://mailman.nginx.org/mailman/listinfo/nginx