|
Dual WAN Config Problem
I have dual PCI ethernet cards as WAN going to a onboard card for the LAN. Now I have read how to use iproute2 and IPTABLES to setup dual WAN routing with load balancing and configure masquerading. One problem I have is that I can't really configure the dual wan as instructed because both WAN cards are on the same gateway/network mask. So it just says file already exists for most of the important commands.
When I get both cards working and do a iptables -L -v I see that one is always taking all the traffic and the other one is never touched, even at max load. If I disable one then the other one kicks in.
What I would like to have is for both cards to work in a way so that if I am doing something with one IP it will go through one card and then if I start doing something else simutaneously with another IP it will use the other card and effectively bounce between the cards to balance the traffic relatively equally between the two cards.
eth0 - LAN
eth1 - WAN 1
eth2 - WAN 2
Both eth1 and eth2 are linksys lne 100tx v5.1 (tulip driver) and the on board eth0 is a broadcom (tg3 driver)
iproute and iptables listings:
192.168.0.0/24 dev eth0 proto kernel scope link src 192.168.0.1
xxx.xxx.208.0/22 dev eth1 proto kernel scope link src xxx.xxx.210.197
xxx.xxx.208.0/22 dev eth2 proto kernel scope link src xxx.xxx.208.253
127.0.0.0/8 dev lo scope link
default via xxx.xxx.208.1 dev eth1
default via xxx.xxx.208.1 dev eth1
---------------------------------------
Chain INPUT (policy ACCEPT 340K packets, 46M bytes)
pkts bytes target prot opt in out source destination
Chain FORWARD (policy ACCEPT 62 packets, 10887 bytes)
pkts bytes target prot opt in out source destination
8165 8083K ACCEPT all -- eth1 eth0 anywhere anywhere state RELATED,ESTABLISHED
6730 846K ACCEPT all -- eth0 eth1 anywhere anywhere
334K 61M LOG all -- any any anywhere anywhere LOG level warning
115K 31M ACCEPT all -- eth2 eth0 anywhere anywhere state RELATED,ESTABLISHED
219K 30M ACCEPT all -- eth0 eth2 anywhere anywhere
Chain OUTPUT (policy ACCEPT 45265 packets, 4283K bytes)
pkts bytes target prot opt in out source destination
----------------------------------------
Yes my route table isn't modified according to the document (in fact this is what it gives my by default) but thats because I can't do the commands. If I use scope global and do next hope I can bounce the network and default routes between the two cards (according to the table), but that doesn't work properly either.
Suggestions/Ideas? (I wanna get this to work in linux, so no I don't want to buy a dual WAN router)
|