Re: [squid-users] Binding question

From: Robert Collins <robert.collins@dont-contact.us>
Date: 29 Aug 2001 00:03:21 +1000

On 27 Aug 2001 13:10:41 -0300, Luiz Lima wrote:
> I have a customer who has two types of connections on a Linux box: ADSL and
> ISDN. The ISDN connection is more expensive, as he pays by usage time.
> However, it is more efficient because it is directly connected to the ISP
> where his websites are hosted.
>
> What we need is a way to define which connection Squid will use depending on
> the originating IP. What I would like to do is this:
>
> - If request comes from 192.168.0.0/24, forward through ppp0 (ADSL using
> Roaring Penguin's PPPoE)
> - If request comes from 192.168.1.0/24, forward through eth2 (connected to
> an external ISDN adapter)
>
> IP Masquerading is doing this fine but we would like to put Squid on top of
> it to be able to restrict access to certain URLs and other things.
>
> Is it possible to configure this setup? None of the connections have a fixed
> IP address.
>

Not really. Squid simply sends the tcp traffic, its up to the machine to route that appropriately.

You could do something like:

main cache (listen on 8080)
parent squid for adsl, no cache storage (listen on 127.0.0.1:8081)
parent squid for isdn, no cache storage (listen on 127.0.0.1:8082)

and have the two parent caches with no storage use the
tcp_outgoing_address command. Then you simply use cache_peer and
cache_peer_access statements in the main cache to select which parent to
go to.

You could get away with only having an explicit parent for the isdn
line.

Rob
Received on Tue Aug 28 2001 - 08:03:11 MDT

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