Re: [SQU] Help! Squid accelerator and Host HTTP header

From: Duane Wessels <wessels@dont-contact.us>
Date: Fri, 8 Dec 2000 21:31:14 -0700 (MST)

On Thu, 7 Dec 2000, Aleksey Zvyagin wrote:

> Hi!
>
> I have squid 2.3-STABLE4
> How can i configure a squid (accelerator mode) that it sends corrected
> "Host:" header to my localhost's httpd server?
>
> For example:
> My apache server listens the 127.0.0.1:80 and has a lot virtual servers at
> one IP address, e.g. 127.0.0.1
> In this time squid is running at this server and listens IP_provider:80
> I have following lines in squid.conf:
>
> httpd_accel_host 127.0.0.1
> httpd_accel_port 80
> httpd_accel_uses_host_header off
>
> If a client connects to IP_provider:80 and requests as:
> GET / HTTP/1.0
> Host: some.my.host
>
> Then the squid requests the 127.0.0.1:80 server as:
> GET / HTTP/1.0
> Host: 127.0.0.1
>
> But i need the "Host: some.my.host"
> If i do:
> httpd_accel_uses_host_header on
> then the squid doesn't connect to 127.0.0.1 but one logs to cache.log
> "Forwarding loop detected..."
> Note: The host some.my.host is resolved by DNS as IP_provider:80 (my server
> has only one IP address from a provider)
>
> Summary of my article: if i have a some virtual WWW servers (Name-based) and
> have only one IP address then i can not run WWW server and squid accelerator
> together at my server... Is it true?

I think you'll need to upgrade to squid-2.4. That version has
this option:

# TAG: httpd_accel_single_host on|off
# If you are running Squid as a accelerator and have a single backend
# server then set this to on. This causes Squid to forward the request
# to this server irregardles of what any redirectors or Host headers
# says.

--
To unsubscribe, see http://www.squid-cache.org/mailing-lists.html
Received on Fri Dec 08 2000 - 21:33:15 MST

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