Re: [squid-users] (squid 3) Reverse proxy - acceleration for multiple webservers with multiple virtual hosts

From: Henrik Nordstrom <henrik@dont-contact.us>
Date: Fri, 05 May 2006 15:54:24 +0200

fre 2006-05-05 klockan 13:45 +0200 skrev Tomasz Marciniak:

> First: reality check - is it possible to use single (for start) Squid as
> acceleration cache for multiple webservers, each one having multiple
> virtual hosts in an architecture like that:

Yes, as long as each site can be identified by Squid..

> Each of webservers has some number of apaches with virtual hosts or
> java-based web applications operating on HTTP.

As long as they are speaking HTTP there is no problem.

> http_port 80 vport

Hmm.. not entirely OK. See the http_port description again. From your
description it sounds like you should be using vhost, and perhaps a
defaultsite as well.

vport -> IP based virtual servers

vhost -> domain based virtual servers

> redirect_rewrites_host_header off

Don't use redirectors if you don't need to.

> http_access allow all

Normally an accelerator/reverse proxy should only allow access to the
sites it acts as an accelerator for..

> cache_peer webserver1.internal parent 80 0
> no-query originserver name=webserver1

Ok.

> cache_peer_access webserver1 allow all
> cache_peer_domain webserver1 webserver1.external.com

Either use cache_peer_access or cache_peer_domain. Mixing the two can be
a bit confusing.. (but works..)

> While trying to retrieve the URL: http://<private_ip_of_squid>/
>
> The following error was encountered:
>
> * Unable to forward this request at this time.

Makes sense. See above.

Regards
Henrik

Received on Fri May 05 2006 - 07:54:44 MDT

This archive was generated by hypermail pre-2.1.9 : Thu Jun 01 2006 - 12:00:02 MDT