Deny access to nginx access denied error log

I have some rule setting in nginx to deny access over IP. This works fine, but for every request with a banned IP message, an error is logged that starts with the following:

[error] 7325#0: *5761 access forbidden by rule, client... 

Is there a way to suppress these "errors" from registration?

+6
source share
1 answer

You can set error_log to a less strict level, but in this case you may lose important warnings.

The main functionality is error_log

 error_log filename crit; 
+3
source

Source: https://habr.com/ru/post/975088/


All Articles