You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by Qingshan Xie <xi...@yahoo.com> on 2014/01/28 19:21:52 UTC
[users@httpd] is there a way to split access_log into two?
Hello,
I'd like to filter some non-business requests into a separate log file. Is there any a way to do it?
Thanks, Q.Xie
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
Re: [users@httpd] is there a way to split access_log into two?
Posted by Daniel Lescohier <da...@cbsi.com>.
Yes, you can use Apache env vars:
CustomLog "|${cronolog} -z GMT ${logpath}/access.${shost}.%Y%m%d%H" common
env=!special_log
CustomLog "|${cronolog} -z GMT ${logpath}/redir.${shost}.%Y%m%d%H"
redirFormat env=rd
<location /redir>
SetEnv rd 1
SetEnv special_log 1
</location>
On Tue, Jan 28, 2014 at 1:21 PM, Qingshan Xie <xi...@yahoo.com> wrote:
> Hello,
>
> I'd like to filter some non-business requests into a separate log
> file. Is there any a way to do it?
>
> Thanks, Q.Xie
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
> For additional commands, e-mail: users-help@httpd.apache.org
>
>