# multiple adsl internet connections

## h0mer`-

hi,

we currently have 2 different adsl internet connections available in a single lan. atm only 1 is used by our squid/dansguardian proxy. how can i make this machine to use both lines equally and still have the proxy/contentfiltering work. do i have to set multiple gateways in the network config or is it possible via some squid tweaking?

thanks.

----------

## qeldroma

Isn't interface bonding possible?

http://www.gentoo-wiki.info/HOWTO_Setup_Bonded_ethernet_adapters

----------

## h0mer`-

thanks for your answer but i think bonding doesnt work in my case because each dsl line has its own router/modem combination.

this is how its atm

users ----- squid/dansguardian - - - - - - dsl1 - - - - - internet

i like to have 

```

                                           dsl1  

                                     /                \

users ---- squid/dansguardian    - -                     --- internet

                                     \                /

                                           dsl2

```

----------

## qeldroma

Ok, so you don't have two physical interfaces, each connected to one direction, but one, connected to... a switch?

----------

## h0mer`-

yes the squid/dansguardian is a virtual machine running on an esx server which is connected to a switch.

----------

## qeldroma

I see no other way than creating a second virtual interface on esx for the squid and then route each interface to one of the DSL's and bond them.

Perhaps someone else has a better idea? AFAIK, only other way would be a physical load-balancer or router with three interfaces for bonding....

I think, the fastest way would really be the routing way, binding one virt.if to one dsl and combine them via bonding in the vm...

Cheers, Florian

----------

## h0mer`-

hmmm, the bonded interface has to have a default gw i guess and the two adsl routers have different ip adresses. so that doesnt solve the problem does it?

----------

## qeldroma

I am not pretty sure, if i can give you a sattisfying answer, but i will try my best  :Wink: 

Perhaps someone else with deeper knowledge should also try this ..

Can you give me some details like net(masks) before and after the squid, IP's and net of the different routers and devices?

Cheers, Florian

----------

## h0mer`-

all devices are in the same subnet 192.168.0.0/24

----------

## nativemad

Hi, 

i think the easiest way would be iproute2!

something like 

```
#ip route add default scope global nexthop via 192.168.1.1 dev eth0 weight 1

 nexthop via 192.168.1.2 dev eth0 weight 2
```

should do it on the squid-box!   :Razz: 

Cheers!

----------

## h0mer`-

awesome thanks.

----------

