*****************
About the "lr"
******************

"lr" is a virtual ethernet device driver and an implementation of
Yumo's original protocol - LRCP (Link Redundancy Configuration Protocol).

"lr" provides multiple virtual interface to kernel (lr0,
lr1...). Each virtual interface works as "group" and it can
contain single or multiple physical interfaces (eth0, eth1...) 
as its stuff (port).
Please refer to protocol documentation (lrcp.pdf) for more information.

By default maximum number of virtual interfaces are 8 and maximum
number of physical interface is same as number of virtual interfaces.

"lrcfg" utility will support to configure each virtual interface
(group) and it comes with "lr" itself or you can download it from
following WWW page.

http://www.st.rim.or.jp/~yumo



************
Usage
************

1. Extract package
  # cd /usr/src
  # tar xzf lr.tar.gz

2. Apply patch to the kernel. This example shows patching to 2.2.x or
   2.4.x kernel. (If you already apply patch which comes with "veth",
   you can skip this step).

  For Linux 2.2.x
  (current directory is /usr/src)
  # patch -p0 < veth-2.2.17.patch

  For Linux 2.4.x
  (current directory is /usr/src)
  # patch -p0 < veth-2.4.x.patch (it depends on the linux version)

3. Rebuild your kernel and install it. Don't forget lilo. then reboot.
  E.g.
  # cd linux
  # make mrproper (linux-2.4, linux-2.6)
  # make menuconfig
  # make dep (linux-2.2, linux-2.4)
  # make bzImage
  # make modules
  # make modules_install
  # make install

4. Build lr and insert module.
  # cd /usr/src/lr
  # make; make install
  # insmod lr.o


  If you fail to make with many errors, check following linux kernel
  configuration.

  Loadable module support | Set version information on all module symbols

  If it is not checked, delete following compile option on the line
  for compiling veth.o in the Makefile and try again.

  -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h

  After compiling, you may want to add following line to
  /etc/modules.conf for demand module loading.

  alias lr0 lr

5. Configure link aggregatoion group.
  # lrcfg add eth0 lr0
  # lrcfg add eth1 lr0

6. Make sure all the links are connected with link aggregatable bridge
   and link aggregation group on the bridge is configured correctly.

7. Configure virtual interface like ethX device.
  # ifconfig lr0 inet 192.168.1.1 netmask 255.255.255.0 up

8. Check lr status. (Each value depends on your environment. This is
   an example.)
  # cat /proc/net/lrcp

GRP     SGM     RCFM    PERIO   
lr0     W_NTR   TMOUT   W_TMOUT 

 Port-Subgroup Mapping
lr0     *eth0(1) : 1
lr0      eth1(2) : 1


 Distributing Information
GRP     Neighbors    SubGRP
lr0     xxxxxx-0fc548    1
lr0     xxxxxx-14e04a    1

9. If there is a active port for a subgroup (marked *), your node 
   can communicate with other nodes via lr0 virtual interface.

10. Remove lr module
  # ifconfig lr0 down
  # rmmod lr



*************
Restrictions:
*************

Frame duplication may occur while following situation.
Because LRCP allows multiple active ports which are connected to 
separate LAN each other.
If such ports connected to single LAN, frame duplication may occur
until rebuild subgroup management table (It takes 1-2 sec). After
that, all the ports will belong to single subgroup and single active 
port is selected. Then frame duplication stops.

Before using lr, please make sure whether your applications or upper
protocols allow fame duplication or not. E.g. TCP can handle frame
duplication collectly so applications which uses TCP is safe to use
lr.  Generally protocols can be used over WAN, it is safe to use
lr because frame duplication and reordering is possible on WAN.


Regards, Yumo//                           )))
Katsuyuki Yumoto                         (((
yumo@st.rim.or.jp                        ~~~~

