Re: how to separate robot access log and human access log

2015-05-05 Thread Francis Daly
On Tue, May 05, 2015 at 08:20:35AM -0400, meteor8488 wrote: Hi there, > if $spiderbot=0, then log to location_access.log Set a variable which is non-zero when $spiderbot=0, and which is zero or blank otherwise. Use that as the access_log if=$variable for location_access.log. > if $spiderbot=1,

Re: how to separate robot access log and human access log

2015-05-05 Thread meteor8488
thanks for your reply. I know that I can use if to enable conditional logging. But what I want to do is if $spiderbot=0, then log to location_access.log if $spiderbot=1, then log to spider_access.log. And I don't want the same logs write to different files. How can I do that? thanks Posted at

Re: how to separate robot access log and human access log

2015-04-30 Thread Francis Daly
On Mon, Apr 27, 2015 at 07:45:17PM -0400, meteor8488 wrote: Hi there, > I'm trying to separate the robot access log and human access log, so I'm > using below configuration: "if=" on the access_log line is what you want. > access_log /web/log/location_access.log main; "No 'if=' there" means "

how to separate robot access log and human access log

2015-04-27 Thread meteor8488
Hi all, I'm trying to separate the robot access log and human access log, so I'm using below configuration: http { map $http_user_agent $ifbot { default 0; "~*rogerbot"3; "~*ChinasoSpider" 3; "~*Yahoo" 1; "~*Bot" 1