Search squid archive

Re: multiple squid boxes on multiple internet connections

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, 17 Nov 2009 22:37:09 +0400, Roguedr <roguedr@xxxxxxxxx> wrote:
> Hi,
> 
> 
> I am stuck in the company with 3 internet connections (3, 1 and 2
> Mbps) that are located in different buildings. The buildings are
> connected together but the LAN is pretty primitive. So far on each
> connection I have a different firewall and users are separated by
> subnet and default gateway to use one of the firewalls.
> As you realize this is a quite inefficient use of the internet
> bandwidth and often I end up with a link saturated while the other
> links have some room to spare.
> 
> 
> Is there a method by which I can set up 3 squid boxes (one on each
> connection) to achieve the following:
> 
> a) if the bandwidth is exhausted on one internet link forward the
> request to the next squid box (with another internet link)
> b) if one box fails have another box handle the traffic
> 
> Point B is less important to me (I guess CARP could be a solution) but
> point A would be a really interesting setup, however I have no idea
> how it could be achieved.
> 
> 
> Is squid cache able to achieve this? Do the wizards on this forum have
> any other suggestions?
> 

Yes Squid can do this with a some tuning of the configuration.

Simplest of all is to have the OS traffic control setting simply balance
the outgoing load between the network links. This is very old technology
and most OS can do it easily.

As you noted CARP would be a good solution to make Squid do it (when
weighted anyway). As would the weighted-round-robin peering method. Both
require a parent Squid that everybody connects to and does load-balancing
between several child Squid each gatewaying an outbound link.

It can also be done with one Squid instance if you are willing to go to
the trouble of working up some complicated measurement and external ACLs.
You can use them as hack to set tcp_outgoing_address and have the OS pass
each outbound down a different link.

NP: Squid-3.2 (still alpha code at the moment) now has a "random" ACL
which will make using tcp_outgoing_address in a weighted load balancing way
much easier.

Amos

[Index of Archives]     [Linux Audio Users]     [Samba]     [Big List of Linux Books]     [Linux USB]     [Yosemite News]

  Powered by Linux