Hi,
Rudy Amid wrote:
> Thanks for the suggestion. I am using the ifconfig alias for virtual
> domains and I find that if I configure just one squid to listen on port 80
> for just one IP address, I'm still connected the other virtual IP address
> into that same one!
> For example, http://www.virtual.hcl.com:80 still
> translates to http://www.virtual.com:80. The real server is listening on
> port 81.
I failed to mention earlier that -V for virtual hosting works for
Squid 1.0. This is what you can use. Squid will use the address that
the client connect to, to determine what virtual host on port 81 to
use. Example:
I have two web sites, www.site1.com and www.site2.com, which are
on 192.168.0.1 and 192.168.0.2, respectively. Both are driven by
Apache listening on port 81.
To accelerate one server only, say www.site1.com, use:
http_port 80
httpd_accel www.site1.com 81
With this setup, even if a browser connects to www.site2.com:80,
they would still see www.site1.com. Squid will always request
for http://www.site1.com:81.
To make both work, use the same configuration as above, but specify -V.
With this, Squid will *ignore* the www.site1.com in the httpd_accel
line, but will use the port 81 specified. Instead, it will look
at the IP address that the browser connected to, and use that as
the request. It does not use the hostname, and will request for
http://192.168.0.1:81 and http://192.168.0.2:81.
> I'm not sure if Apache 1.1.1 lets me configure the virtual hostname to
> listen on other ports. That way I don't have to run more than
> one squid on a less busy virtual hostname.
I believe the BindAddress directive does it. As shipped, Squid
virtual hosting doesn't work for Host: header based virtual hosting,
which Apache does if you don't specify a BindAddress.
Hope this helps!
-- miguel a.l. paraz <map@iphil.net> http://www.iphil.net/~map/ PGP: 0x43F0D011 iphil communications: isp/intranet design and implementation, makati city, phReceived on Sun Oct 27 1996 - 00:21:33 MDT
This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:33:22 MST