> -----Original Message-----
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of 
> Joshua Slive
> Sent: Wednesday, August 02, 2006 1:31 AM
> To: users@httpd.apache.org
> Subject: Re: [EMAIL PROTECTED] Using env vars to compliment logging
> 
> On 8/1/06, Dan Trainor <[EMAIL PROTECTED]> wrote:
> > Hello, all -
> >
> > For sake of trying to sound clever, I'll just flat-out say what I'm
> > looking for, instead of using a real example.
> >
> > We use a wildcard approach in a VirtualHost container to accept
> > requests, and it works quite well.  However, I am having 
> trouble making
> > logs for each actual server name which I'm serving.
> >
> > Ideally I'd like something such as:
> >
> > Customlog /path/to/logs/$HTTP_HOST-access.log combined
> >
> > to create /path/to/logs/domain.tld-access.log.
> >
> > Do I have this flexibility, or would I have to consider 
> alternate routes?
> 
> No, you can't use env variables in CustomLog definitions.  
> The docs are here:
> http://httpd.apache.org/docs/2.2/logs.html#accesslog
> 
> You have two choices:
> 
> 1. Put everything into one logfile and split it later using something
> like the split-logfile program included with apache.
> 
> 2. Put a separate CustomLog directive in each <VirtualHost> section.

If I understood the OP correctly, he wants ever more fine-grained
control than that - he wants separate logs for different ServerAliases
*within* a VH... ("wildcard approach in a VirtualHost container").

That can't be done and you'd have to define a separate VH for each alias
(ie, expand the aliases into full VHs). As described in (1) above, the
better approach is to parse a global logfile later - you can put the
hostname into the LogFoprmat with %{Host}i.

Rgds,
Owen Boyle
Disclaimer: Any disclaimer attached to this message may be ignored. 


> 
> Joshua.
> 
> ---------------------------------------------------------------------
> The official User-To-User support forum of the Apache HTTP 
> Server Project.
> See <URL:http://httpd.apache.org/userslist.html> for more info.
> To unsubscribe, e-mail: [EMAIL PROTECTED]
>    "   from the digest: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
 
 
This message is for the named person's use only. It may contain confidential, 
proprietary or legally privileged information. No confidentiality or privilege 
is waived or lost by any mistransmission. If you receive this message in error, 
please notify the sender urgently and then immediately delete the message and 
any copies of it from your system. Please also immediately destroy any 
hardcopies of the message. You must not, directly or indirectly, use, disclose, 
distribute, print, or copy any part of this message if you are not the intended 
recipient. The sender's company reserves the right to monitor all e-mail 
communications through their networks. Any views expressed in this message are 
those of the individual sender, except where the message states otherwise and 
the sender is authorised to state them to be the views of the sender's company.

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: [EMAIL PROTECTED]
   "   from the digest: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to