Re: http_accel, virtual hosts, and logging.

From: Greg Retkowski <greg@dont-contact.us>
Date: Tue, 4 Apr 2000 13:28:54 -0700 (PDT)

On Sun, 2 Apr 2000, Henrik Nordstrom wrote:

> Greg Retkowski wrote:
>
> > several virtual hosts. My problem is that my configuration generates URL
> > logs like:
> >
> > 954291569.255 85 128.209.24.253 TCP_MISS/200 3250 GET
> > http://localhost/ldap/ - DIRECT/localhost text/html
> >
> > However I need something like:
> >
> > 954291569.255 85 128.209.24.253 TCP_MISS/200 3250 GET
> > http://www.rage.net/ldap/ - DIRECT/localhost text/html
> >
> > so that I can account for which virtual sites are recieving the traffic.
>
> You also need it to not mess up the virtual hosts. What is logged is
> what Squid requests from your web server.

Squid appears to be logging the host it contacts, regardless of which
'virtual host' it is really getting content for. I would propose that
logging the host header, if present, is more useful then logging the
contacted host because:

 1. The 'host header' will allways resolve the contacted host; i.e.
   nslookup www.virtual-host.com will give the IP address of the real
   server.

 2. There may/will be multiple virtual hosts for each real host but
   not many real hosts per virtual host.

 3. The host header provides information as to which virtual host
   is contacted. But no information is lost by not logging the
   real host contacted (the current implementation).

The thing I do not like about setting a bunch of hostnames to localhost in
the hosts file is that it may interfere with other software referencing
these hostnames.

-- Greg

Greg Retkowski Mail: greg@rage.net
Raging Network Services URL: http://www.rage.net/
Received on Tue Apr 04 2000 - 14:35:29 MDT

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:52:41 MST