Welcome! Log In Create A New Profile

Advanced

Location based access log

August 05, 2011 03:17PM
Hi all. I'm trying to log request to a specific directory to an alternate access_log. The docs suggest the access_log can be specified in the http, server, or location level. eg:

server {
access_log /var/log/nginx/access_log;
location /api/ {
access_log /var/log/nginx/api.access_log;
}
}

In my case, everything is logged the main access_log, and although the file gets created for the api.access_log, nothing gets logged to it.

Am I missing something?

Thanks in advanced.
-Jason
Subject Author Posted

Location based access log

houseofmore August 05, 2011 03:17PM

Re: Location based access log

Ensiferous August 07, 2011 07:12AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 68
Record Number of Users: 6 on February 13, 2018
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready