Welcome! Log In Create A New Profile

Advanced

Re: How to disable access_log to images but log 404s

grrm grrm
October 30, 2014 02:18PM
Hi. Maybe you can do something like:
location ^~ /res/ {
error_page 404 /res/images/100candles-logo-square.png;
expires 14d;
access_log off;
location = /res/images/100candles-logo-square.png {
access_log on;
}
}


2014-10-30 15:56 GMT+02:00 Igal @ getRailo.org <igal@getrailo.org>:
> hi,
>
> I am suppressing the access_log for images and other files in the /res/
> directory:
>
> location ^~ /res/ {
>
> error_page 404 /res/images/100candles-logo-square.png;
> expires 14d;
> access_log off;
> }
>
> but I would like to log the 404s in the access_log
>
> how can I do that?
>
> TIA
>
> _______________________________________________
> nginx mailing list
> nginx@nginx.org
> http://mailman.nginx.org/mailman/listinfo/nginx

_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

How to disable access_log to images but log 404s

Igal @ getRailo.org October 30, 2014 09:58AM

Re: How to disable access_log to images but log 404s

wandenberg October 30, 2014 10:34AM

Re: How to disable access_log to images but log 404s

grrm grrm October 30, 2014 02:18PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 232
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready