I believe there''s an option in the kernel for that, and quite possibly a howto as well. www.linux.org, check the docs section there hth, at least a bit -Hexxor http://nanook.ath.cx/ http://rains.net/~hexxor/ "Do not take for granted, the powers out there." GMUd-s:--a--C++UL++++P++++L++++E----W++N+o+K-O- w---M-V-PS+++PEY+PGPt---5--X-R!tvb+DID+Geh--ry+
Hi, can anyone help me with this problem i''ve got! I have a problem with routing on my Mandrake 7.2 Linux Box i was wondering if you could help me with. I live in Australia and as broadband access isn''t very available at the moment, i have 2 modems to dialup to my isp (dynamic ips assigned) to increase my bandwidth at an affordable level. What currently happens is i have a LAN which accesses the internet through my Box that has IP Masquerading set up on it. My problem is whne i dial in with both connections, it only routes the internet through the last ppp connection i''ve made (usually ppp1). This means that although ppp0 and ppp1 are connected to the internet, my computers on the LAN (ip 192.168.1.x) are only connecting through one modem. What I need is to know how to set up routing, or Loadsharing so that i can utilise both modems over my Masqed network. What happens when i type route -n in the command line: Destination Gateway Genmask Flags Metric Ref Use Iface 198.142.149.254 0.0.0.0 255.255.255.255 UH 0 0 0 ppp0 198.142.150.254 0.0.0.0 255.255.255.255 UH 0 0 0 ppp1 192.168.0.0 0.0.0.0 255.255.255.0 U 0 0 0 eth0 127.0.0.0 0.0.0.0 255.0.0.0 U 0 0 0 lol 0.0.0.0 198.142.150.254 0.0.0.0 UG 0 0 0 ppp1 My Desired Set Up: Internet Internet | | | | |ppp0 |ppp1 | | ____________________________ | Linux Box | | IP Masquerading | | routing or lOadsharing | -------------------------------------------------- | | |eth0 | The Rest of My Lan Any assistance with my problem would be greatly appreciated. Cheers -Lisle Wilson
Arthur van Leeuwen
2000-Dec-04 08:05 UTC
Re: Load Sharing PPP Connections on an Masqed LAN
On Mon, 4 Dec 2000, Lisle Wilson wrote:> My problem is whne i dial in with both connections, it only routes the > internet through the last ppp connection i''ve made (usually > ppp1). This means that although ppp0 and ppp1 are connected to > the internet, my computers on the LAN (ip 192.168.1.x) are only > connecting through one modem.You have set the `defaultroute'' option to PPP. This is its intended effect.> What I need is to know how to set up routing, or > Loadsharing so that i can utilise both modems over my Masqed network.> My Desired Set Up: > > Internet Internet > | | > |ppp0 |ppp1 > | | > _______________________________________ > | Linux Box | > | IP Masquerading | > | routing or lOadsharing | > -------------------------------------------------- > | > |eth0 > | > The Rest of My LanOoooooh, an ASCII-gram. First: read up on the ''ip'' tool that comes with iproute2. Second: set up /etc/ppp/ip-up.local scripts (not exactly sure what Mandrake uses for that, but that''s what RedHat uses) to dynamically reroute to the correct interfaces Third: make a multipath route over the two ppp links. This will dynamically balance packets over the two links, based on the destination adresses. Hope this helps. Doei, Arthur. -- /\ / | arthurvl@sci.kun.nl | Work like you don''t need the money /__\ / | A friend is someone with whom | Love like you have never been hurt / \/__ | you can dare to be yourself | Dance like there''s nobody watching
On Dec 04 2000, Arthur van Leeuwen wrote:> Second: set up /etc/ppp/ip-up.local scripts (not exactly sure what Mandrake > uses for that, but that''s what RedHat uses) to dynamically reroute > to the correct interfacesCould you provide more information on what is meant by "dynamically reroute"? By that you mean that ppp shouldn''t add default routes to the gateways?> Third: make a multipath route over the two ppp links. This will dynamically > balance packets over the two links, based on the destination adresses.Which way would I do this? Should I delete my default route and use: # ip route add default scope global nexthop dev ppp0 nexthop dev eth0 (so that I can use both my ppp connection and my DSL?) I tried the above and it "partially" works: I have problems accessing some www sites (Netscape shows me "No route to host"), while accessing others is fine (I can read slashdot ok). It seems that the problem only occurs with TCP based services (UDP based ones seem to be fine -- ICMP echo also seems fine). Any suggestion what I should be doing to correct this? Thank you very much for any comments, Roger... -- =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- Rogerio Brito - rbrito@iname.com - http://www.ime.usp.br/~rbrito/ =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Arthur van Leeuwen
2000-Dec-05 15:37 UTC
Re: Load Sharing PPP Connections on an Masqed LAN
On Tue, 5 Dec 2000, Rogerio Brito wrote:> On Dec 04 2000, Arthur van Leeuwen wrote: > > Second: set up /etc/ppp/ip-up.local scripts (not exactly sure what Mandrake > > uses for that, but that''s what RedHat uses) to dynamically reroute > > to the correct interfaces > > Could you provide more information on what is meant by > "dynamically reroute"? By that you mean that ppp shouldn''t add > default routes to the gateways?Oh, no. By that I mean that the ip-up.local script should set the route itself, depending on whether there are one or two ppp links up already. This is relatively easy to figure out using ''ip addr'' and some awk.> > Third: make a multipath route over the two ppp links. This will dynamically > > balance packets over the two links, based on the destination adresses. > > Which way would I do this? Should I delete my default route > and use: > > # ip route add default scope global nexthop dev ppp0 nexthop dev eth0That is correct.> (so that I can use both my ppp connection and my DSL?) > > I tried the above and it "partially" works: I have problems > accessing some www sites (Netscape shows me "No route to > host"), while accessing others is fine (I can read slashdot > ok). > > It seems that the problem only occurs with TCP based services > (UDP based ones seem to be fine -- ICMP echo also seems fine). > > Any suggestion what I should be doing to correct this?You should add gateways for the different outgoing devices and set up host routes to those gateways specifying as the preferred source address the address associated with the interface through which you route to the gateway. Further, adding rulesets to deal with the case that packets already have a source address set might greatly improve reliability. There''s some information on how to do that in some previous mails I made to the list. Doei, Arthur. -- /\ / | arthurvl@sci.kun.nl | Work like you don''t need the money /__\ / | A friend is someone with whom | Love like you have never been hurt / \/__ | you can dare to be yourself | Dance like there''s nobody watching