Re: [squid-users] configuring squid to go directly in case of upstream proxies are down

From: Amos Jeffries <squid3_at_treenet.co.nz>
Date: Tue, 29 May 2012 23:07:12 +1200

On 29/05/2012 10:13 p.m., nipun_mlist Assam wrote:
> Is there any way through which I can control traffic from only few
> clients to connect directly to internet if the upstream parent proxies
> are down.
> For example, in an example configuration squid forwards traffic from
> client C1 and C2 to parent proxy P.
>
> HTTP traffic from client C1 and C2<---> forwarding squid<---> P<---> cloud
>
> If parent P is down I want C1's traffic to be sent directly to the
> internet by squid, while for C2 the connection should be dropped by
> squid.
>
> "prefer_direct off" affects traffics from all the clients.
> Is there any way to use a combination of "prefer_direct off" and
> "never_direct allow all/ always_direct deny all" ?

never_direct and allow_direct are lists with multiple lines performing
if-else logic just like http_access.

Think about it like this: you said you want these clients to go direct
*sometimes*, so why are you setting them to *never* go direct? ("all"
matches everything).

prefer_direct determins whether the parent or DIRECT are *tried* first.
First route to succeed suplies the answer.

Amos
Received on Tue May 29 2012 - 11:07:23 MDT

This archive was generated by hypermail 2.2.0 : Tue May 29 2012 - 12:00:05 MDT