Re: Virtual servers..

From: Henrik Nordstrom <hno@dont-contact.us>
Date: Wed, 25 Mar 1998 17:28:53 +0100

Spencer P. wrote:
>
> I have many virtual servers on one machine I wish to cache. I did the
> httpd_accel server port virtual for each server but that just winds up
> with squid pulling all data for all ip's from the last ip. Anyone do this
> before?

Only one httpd_accel line is allowed in squid.conf, and the magic
hostname "virtual" tells squid that it should use the IP where it got
the connection.

If your virtual servers uses different IP addresses (which I assume
based on what you write) then squid.conf should read

httpd_accel virtual 80
redirect_program /path/to/your/redirector

And write a small redirector to redirect the different IP addresses used
for acceleration to the real IP for the servers.

If your virtual hosts is based on the Host: header (sharing one IP
address) then squid.conf should read

httpd_accel your.main.server 80
httpd_accel_uses_host_header on

no redirector is needed.

If you use a mixture of Host: and IP based servers, you should use
1.1.21 or lated (or apply a small patch), and combine both metods above.

---
Henrik Nordström
Sparetime Squid Hacker
Received on Wed Mar 25 1998 - 10:22:59 MST

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