Mesh Networking with OLSR

From DD-WRT Wiki

(Difference between revisions)
Jump to: navigation, search
Revision as of 18:41, 6 October 2008 (edit)
Sash (Talk | contribs)
m (v.24 Final Broadcom)
← Previous diff
Revision as of 18:42, 6 October 2008 (edit) (undo)
Sash (Talk | contribs)
m (External Links)
Next diff →
Line 194: Line 194:
<br> <br>
<br> <br>
-===External Links===+==External Links==
[http://staros.tog.net/wiki/OLSR staros_olsr] [http://staros.tog.net/wiki/OLSR staros_olsr]
<br><br> <br><br>
--[[User:Sash|Sash]] 22:00, 7 June 2008 (CEST) --[[User:Sash|Sash]] 22:00, 7 June 2008 (CEST)

Revision as of 18:42, 6 October 2008


Contents

General

What is mesh networking?

Mesh networking is used to route data, voice and instructions between nodes (typically routers). A mesh network typically consists of 2 or (many) more nodes, which exchange information about their connection-status with each other (routing updates), so that every node knows, which path he has to take to reach any other node in the mesh. When a node wants to reach another node that is not directly connected, the traffic flows over other nodes, until the final node is reached (hopping) -each node that the traffic flows through is called a hop.

Why mesh networking?

Mesh networks differ from other networks in that the component parts can all connect to each other via multiple hops. Mesh networks are self-healing: the network can still operate even when a node goes down or a connection drops. The result is a very reliable network.

Benefits of mesh networking

  • self organizing
  • self-healing
  • low system maintenance needed
  • robust due dynamic route recalculation

Disadvantages of mesh networking

  • additional network traffic

The exchange of routing information (routing updates) can produce a lot of traffic-overhead, also every device that takes part of a mesh must have enough cpu/ memory to have an overview of all other routers and how to reach them. (routing table). A full routing table can get very large - as seen in BGP-Routing: a full BGP table needs 2GB of memory (300.000 active routes). There is also a danger of routing-loops that can appear because of weak routing information.

OLSR

General

OLSR is a dynamic linkstate Protocol which collects link data and dynamically calculates the best routes within the network.

Links:

http://en.wikipedia.org/wiki/OLSR
http://www.olsr.org

Parameters

General:

  • IpVersion
  • AllowNoInt
  • Pollrate
  • TcRedundancy
  • MprCoverage
  • LinkQualityFishEye
  • LinkQualityWinSize
  • LinkQualityDijkstraLimit

per Interface:

  • HelloInterval
  • HelloValidityTime
  • TcInterval
  • TcValidityTime
  • MidInterval
  • MidValidityTime
  • HnaInterval
  • HnaValidityTime
  • LinkQualityMult

HNA4

IcpConnect

Plugins:

Sample config file:

DebugLevel              0
IpVersion               4
AllowNoInt              yes
Pollrate                0.1
TcRedundancy            2
MprCoverage             7
LinkQualityFishEye      1
LinkQualityWinSize      100
LinkQualityDijkstraLimit 0 7.0
LoadPlugin "olsrd_txtinfo.so.0.1"
{
       PlParam "Accept" "127.0.0.1"
}
Hna4
{
}
IpcConnect
{
       MaxConnections  1
       Host            127.0.0.1
       Net 192.168.1.0 255.255.255.0
}
LinkQualityLevel 2
UseHysteresis no
Interface "eth1"
{
       HelloInterval           5.0
       HelloValidityTime       90.0
       TcInterval              3.0
       TcValidityTime          270.0
       MidInterval             15.0
       MidValidityTime         270.0
       HnaInterval             15.0
       HnaValidityTime         90.0
       LinkQualityMult 10.100.2.5 0.5
}
Interface "vlan1"
{
       HelloInterval           5.0
       HelloValidityTime       90.0
       TcInterval              3.0
       TcValidityTime          270.0
       MidInterval             15.0
       MidValidityTime         270.0
       HnaInterval             15.0
       HnaValidityTime         90.0
       LinkQualityMult 10.100.2.5 0.5
}

Setup

DD-WRT > v.23 SP3

try the following steps to get OLSR running: under Wireless -> Basic Settings

  • enable adhoc mode
  • set our wlan mode (b,g,mixed...)
  • set your SSID
  • set your channel
  • unbridge the wlan
  • set an ip
  • set the network mask to e.g.255.255.255.0

under Setup -> Advanced Routing

  • set Operating Mode to OLSR
  • keep the basic olsr settings. they are ok for the first tests
  • add the correct wlan interface to olsr (e.g. on most buffalos its eth1)
  • keep the interface settings for testing

v.24 Final Broadcom

we have a bug in the broadcom tree that pevents olsr to run correct. olsr should work ok with settings above, but with the bug the wlan interface is NOT correctly unbridged in adhoc mode. connect to the device via telnet or ssh and check the following output.
UPDATE: the bug is fixed in builds > 9503

wl status

should show your device in adhoc mode. rssi & noise should have equal values as below, NOT 0dBm (in this case you should reboot and check again)!

SSID: "dd-wrt"
Mode: Ad Hoc    RSSI: -49 dBm   noise: -96 dBm  Channel: 10
BSSID: 2E:12:8F:xx:xx:xx        Capability: IBSS
Supported Rates: [ 1(b) 2(b) 5.5(b) 11(b) ]

and

ifconfig

there should be shown the ip you set for the wlan interface. here its eth1

eth1      Link encap:Ethernet  HWaddr 00:16:01:xx:xx:xx
          inet addr:10.0.10.4  Bcast:10.0.10.255  Mask:255.255.255.0
          UP BROADCAST RUNNING ALLMULTI MULTICAST  MTU:1500  Metric:1
          RX packets:2337 errors:0 dropped:0 overruns:0 frame:860
          TX packets:2940 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:172534 (168.4 KiB)  TX bytes:234432 (228.9 KiB)
          Interrupt:2 Base address:0x5000

if not, set your ip manualy like this

ifconfig "your wlan interface, e.g. eth1" netmask "your netmask, e.g. 255.255.255.0" 

and check ifconfig again

if everything is ok, connect to http:"your-router-ip":8080. Here you have the OSLR interface and you can see the connected nodes on the Links tab.

THIS INSTRUCTION BELOW DOESNT WORK CAUSE OF THE BUG
to the fact that this settings will be resetted at reboot you can write them to the nvram to have them stored permanetly.
you have to write the ip and the subnetmask to the nvram. this is an example for the wlan interface of the whr-g54 router where eth1 is the wlan-if and the ip i used above.

nvram set eth1_ipaddr=10.0.10.4
nvram set eth1_netmask=255.255.255.0
nvram commit



External Links

staros_olsr

--Sash 22:00, 7 June 2008 (CEST)