Subject: Re: multiple dialout PPPs?
To: None <jfw@jfwhome.funhouse.com>
From: Roland McGrath <roland@frob.com>
List: current-users
Date: 04/24/1995 17:59:35
I have been interested in exactly the same thing, but haven't gotten
around to getting it working (I need to get around to buying the
second modem first).
My PPP peer is a Livingston Portmaster 2E. These boxes support
multiple PPP connections with the same IP address on multiple modem
lines. support@livingston.com told me that their "load balancing"
algorithm is utterly simple: when a packet arrives for your IP
address, the Portmaster looks at the queue of packets waiting to go
out each PPP interface with that address, and choses the interface
whose queue consumes the fewest bytes.
My (simple) idea was to implement a "mux" interface, which is attached
to an arbitrary number of underlying real interfaces. The mux
interface is used only for output. Input packets arrive on one PPP
interface or the other normally, and I think that works fine (just
like having an ethernet interface and a ppp interface with the same
address works fine). For each output packet, the mux interface
examines each of its underlying interfaces and queues the packet on
the least loaded interface.
I have not tried to address at all the hard parts of dealing with the
underlying interfaces going up and down dynamically and such. A lot
of work is needed for this is straight single-line PPP anyway.
I wrote some simple code for this and made it a loadable kernel
module, but haven't really debugged it. I had trouble with the
routing and didn't bother to go grok all the networking code to figure
it out. (Obviously one needs somehow to make sure the route to the
PPP peer's IP address is through the mux interface rather than one of
the PPP interfaces.)
For configuration (i.e. which underlying interfaces to demux onto) I
have a total kludge: "ifconfig mux0 ADDR" tells it to scan the
interfaces and attach to all the point-to-point interfaces with that
address.
As I said, I never really got this working, but the idea is simple and
I'm sure the debugging is straightforward for someone who understands
the network code better than I do. If anyone wants to pick this up
and do something with it, I'll send you my code (~200 lines, very
boring).
Roland