Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 13 Jul 2004 17:38:24 -0500
From:      Eric Crist <ecrist@secure-computing.net>
To:        freebsd-questions@freebsd.org
Cc:        Chris Burchell <cburchell@muttart.org>
Subject:   Re: Apache and split logs
Message-ID:  <200407131738.24892.ecrist@secure-computing.net>
In-Reply-To: <1B36135783A3254A8C024188C0E3DFEC096435@dsl-main-66-18-201-230-edm.nucleus.com>
References:  <1B36135783A3254A8C024188C0E3DFEC096435@dsl-main-66-18-201-230-edm.nucleus.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Tuesday 13 July 2004 16:45, Chris Burchell wrote:
> Is there any way (script / apache module / other) I can have the apache
> access-log split into separate access logs for individual virtual sites
> hosted on a FreeBSD box?
>
> -FreeBSD 4.10
> -Apache 1.3.31
>
> Thanks,
> Chris
> _______________________________________________
> freebsd-questions@freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-questions
> To unsubscribe, send any mail to
> "freebsd-questions-unsubscribe@freebsd.org"

Yes.  Simply set a log line in your VirtualHost directive.  Here are mine as 
an example:

<VirtualHost www.e-u-a.net>
    ServerAdmin webmaster@e-u-a.net
    DocumentRoot /www/e-u-a.net/
    DirectoryIndex index.htm index.html index.php
    ServerName www.e-u-a.net
    ErrorLog /var/log/eua_error.log
    CustomLog /var/log/eua_access.log common
</VirtualHost>

This puts the logfile for eua into eua_error.log and eua_access.log.  You can 
put most directives listed in the config file into the VirtualHost directive.

HTH
-- 
Eric F Crist

Keep your pecker hard and your powder dry, and the world WILL turn.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200407131738.24892.ecrist>