Hello all. I am not 100% familiar with the Linux advanced routing capbalieties yet, so I thought , after reading source code, documentation and more that I might be better off asking the experts on this list. I am not using this ina production environment, but at home, as a test case. First of all, here is the network topology. Internal LAN <--> Switch <--> [NAT/FIREWALL/INTERNAL LAN DEFAULT GATEWAY] | | | | | | ISP DEFAULT GW 1 ISP DEFAULT GW 2 \ / \ / INTERNET Now, while I know how to use multiple default gateways, I do not know how to equally divert traffic onto those gateways. The idea is the following. My ISP is not the most reliable cable services provider and often one gateway will fail, when the other is still active. Those system glitches last anywhere from 30 seconds to 2 hours. I was thinking about writing a little flow watcher, that looks at how many packets are being resent and then drops one DGW in case it has "fallen off the net". Is it actually possible to have packet 1 go via GW1 and packet 2 via GW2 then packet 3 via 1 and packet 4 via 2 nad so on? As I said, this is a test case and I do not mind installing Zebra if that is necessary, I just wanted to know if this is possible with iproute2 and maybe a specialzed form of shaping? Thank you in advance. -d --- ...my faith in love is like blood, I spill it freely for some..my faith in love is like blood, it flows in everyone.
bert hubert
2001-Dec-07 15:36 UTC
Re: dividing traffic equally towards 2 default gateways?
On Fri, Dec 07, 2001 at 03:32:11PM +0100, Darian Lanx wrote:> Now, while I know how to use multiple default gateways, I do not know how > to equally divert traffic onto those gateways. The idea is the following. > My ISP is not the most reliable cable services provider and often one > gateway will fail, when the other is still active. Those system glitches > last anywhere from 30 seconds to 2 hours. I was thinking about writing a > little flow watcher, that looks at how many packets are being resent and > then drops one DGW in case it has "fallen off the net". Is it actually > possible to have packet 1 go via GW1 and packet 2 via GW2 then packet 3 > via 1 and packet 4 via 2 nad so on? As I said, this is a test case and I > do not mind installing Zebra if that is necessary, I just wanted to know > if this is possible with iproute2 and maybe a specialzed form of shaping?It''s all pretty difficult and doesn''t work all too well. Use "ip route replace" to easily change your default gw. Detection of a dead link is pretty hard, and not something for the kernel to do. Sometimes the kernel can detect a dead link, but that''s only on ARPing mediums and in the case where the gateway doesn''t ARP anymore. Regards, bert -- http://www.PowerDNS.com Versatile DNS Software & Services Trilab The Technology People Netherlabs BV / Rent-a-Nerd.nl - Nerd Available - ''SYN! .. SYN|ACK! .. ACK!'' - the mating call of the internet