2011年2月22日星期二

Re: Need to exclude file from server logs

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 02/22/2011 12:26 PM, bindsocket wrote:
> Dont know if this is even possible but I have a healthcheck file
> that is checked by a load balancer every 30 seconds. However, I
> really do not want the webserver to be logging this. Is there some
> way to configure the server to ignore a file or directory as far as
> the logging is concerned??
>
> Running nginx 0.7.65 on Ubuntu 10.04
>


I don't know if it's the best way to configure a healthcheck, but:

location = /healthcheck_nginx.html {
access_log off;
root /usr/share/nginx/html;
index healthcheck_nginx.html;
}


hope this helps.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAk1j2CUACgkQNRQApncg296c9gCdFQ15ofUwV1lsrqMv72fRcQn2
0xgAn10L3OT0f2rlvabrOriLz3kYk0UC
=3UMW
-----END PGP SIGNATURE-----


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

没有评论:

发表评论