Project

General

Profile

BATMAN V Tests

The following tests have been performed on OpenWRT with emulation setup to test convergence times.

Configuration:

Each scenario has been tested with a corresponding setup script (see attached). Links have been killed using the commands as stated in each test report.

OpenWRT commands to set up the nodes after bootup:

NUM=$(ifconfig eth0| grep HWaddr | sed 's/:01[\n\ ]*$//' | sed 's/.*://'| sed 's/[\n\ ].*//')
batctl if del eth0
batctl if del eth1
ifconfig br-lan down
brctl delbr br-lan
batctl ra BATMAN_IV
ifconfig eth0 up
ifconfig eth1 up
batctl if add eth0
batctl if add eth1

ifconfig bat0 hw ether FE:F1:00:00:${NUM}:01
ifconfig bat0 inet 192.168.0.$(printf %d 0x${NUM}) up

Originator interval:

  • B.A.T.M.A.N. IV: 1 second (default)
  • B.A.T.M.A.N. V: 1 second (default)

Tests

Host restart

Scenario: 2 nodes talking to each other (any of the scripts will work)

On one node, run:

batctl if del eth0 ; batctl if del eth1
sleep 1
batctl if add eth0 ; batctl if add eth1

Results:

B.A.T.M.A.N. IV: OGM table recovers within 30 seconds
B.A.T.M.A.N. V: OGM table recovers within 30 seconds

Both recovery times are due to the protection window

Convergence times

The triangle

Scenario:

Pinging from node 1 and 2
killing connection between 1 and 2 by kill $(cat killme.pid)

Results:

B.A.T.M.A.N. V: 6 seconds to recover
64 bytes from 192.168.0.2: seq=10 ttl=64 time=0.423 ms
64 bytes from 192.168.0.2: seq=11 ttl=64 time=1.055 ms
64 bytes from 192.168.0.2: seq=16 ttl=64 time=2.174 ms
B.A.T.M.A.N. IV: 6 seconds to recover
64 bytes from 192.168.0.2: seq=8 ttl=64 time=0.870 ms
64 bytes from 192.168.0.2: seq=9 ttl=64 time=1.430 ms
64 bytes from 192.168.0.2: seq=15 ttl=64 time=2.391 ms
64 bytes from 192.168.0.2: seq=16 ttl=64 time=2.190 ms

The circle, I

ping from B to A (ping 192.168.0.11)
batctl o | grep fe:f0:00:00:0b:01 --> verify direction (flaps often in BATMAN IV)
kill $(cat killmeTOP.pid)
kill $(cat killmeBOTTOM.pid)
B.A.T.M.A.N. V: 6 seconds to recover
64 bytes from 192.168.0.11: icmp_req=7 ttl=64 time=2.45 ms
64 bytes from 192.168.0.11: icmp_req=8 ttl=64 time=1.88 ms
64 bytes from 192.168.0.11: icmp_req=14 ttl=64 time=3.33 ms
64 bytes from 192.168.0.11: icmp_req=15 ttl=64 time=4.41 ms
B.A.T.M.A.N. IV: 6 seconds to recover
64 bytes from 192.168.0.11: icmp_req=1 ttl=64 time=4.13 ms
64 bytes from 192.168.0.11: icmp_req=2 ttl=64 time=3.47 ms
64 bytes from 192.168.0.11: icmp_req=8 ttl=64 time=4.21 ms
64 bytes from 192.168.0.11: icmp_req=9 ttl=64 time=283 ms

The circle, II

ping from N12 to A, since this was taking the top path
kill $(cat killmeBOTTOM.pid)
B.A.T.M.A.N. V: 5 seconds to recover
64 bytes from 192.168.0.1: icmp_req=4 ttl=64 time=4.43 ms
64 bytes from 192.168.0.1: icmp_req=5 ttl=64 time=4.61 ms
64 bytes from 192.168.0.1: icmp_req=10 ttl=64 time=3.66 ms
64 bytes from 192.168.0.1: icmp_req=11 ttl=64 time=3.53 ms
B.A.T.M.A.N. IV: 6 seconds to recover
64 bytes from 192.168.0.1: icmp_req=20 ttl=64 time=3.21 ms
64 bytes from 192.168.0.1: icmp_req=21 ttl=64 time=2.80 ms
64 bytes from 192.168.0.1: icmp_req=22 ttl=64 time=3.95 ms
64 bytes from 192.168.0.1: icmp_req=28 ttl=64 time=2.83 ms

The bottle

ping from B to A
kill top or bottom, depending on which path is active
kill $(cat killmeTOP.pid)
kill $(cat killmeBOTTOM.pid)
B.A.T.M.A.N. V: 6 seconds to recover
64 bytes from 192.168.0.9: icmp_req=3 ttl=64 time=4.28 ms
64 bytes from 192.168.0.9: icmp_req=9 ttl=64 time=3.71 ms
64 bytes from 192.168.0.9: icmp_req=10 ttl=64 time=4.42 ms
64 bytes from 192.168.0.9: icmp_req=11 ttl=64 time=4.17 ms
B.A.T.M.A.N. IV: 6 seconds to recover
64 bytes from 192.168.0.9: icmp_req=2 ttl=64 time=4.18 ms
64 bytes from 192.168.0.9: icmp_req=3 ttl=64 time=3.45 ms
64 bytes from 192.168.0.9: icmp_req=9 ttl=64 time=4.00 ms
64 bytes from 192.168.0.9: icmp_req=10 ttl=64 time=3.96 ms

Mobility

While A is moving through the mesh the route between A and B shall recover as fast as possible.

New neighbor

from A (7): ping 192.168.0.3 (B in the graph)
kill $(cat killmeMOBILE.pid) ; \
wirefilter --daemon -v num0_7.ctl:num0_2.ctl --pidfile killmeMOBILE.pid
kill $(cat killmeMOBILE.pid) ; \
wirefilter --daemon -v num0_7.ctl:num0_1.ctl --pidfile killmeMOBILE.pid
B.A.T.M.A.N. V:
1->2: 5 seconds
64 bytes from 192.168.0.3: icmp_req=11 ttl=64 time=1.53 ms
64 bytes from 192.168.0.3: icmp_req=12 ttl=64 time=2.13 ms
64 bytes from 192.168.0.3: icmp_req=17 ttl=64 time=1.23 ms
64 bytes from 192.168.0.3: icmp_req=18 ttl=64 time=1.54 ms
2->1: 5 seconds
64 bytes from 192.168.0.3: icmp_req=5 ttl=64 time=1.08 ms
64 bytes from 192.168.0.3: icmp_req=6 ttl=64 time=2.26 ms
64 bytes from 192.168.0.3: icmp_req=11 ttl=64 time=2.03 ms
64 bytes from 192.168.0.3: icmp_req=12 ttl=64 time=1.98 ms
B.A.T.M.A.N. IV:
1->2: 11 seconds
64 bytes from 192.168.0.3: icmp_req=34 ttl=64 time=1.88 ms
64 bytes from 192.168.0.3: icmp_req=35 ttl=64 time=1.07 ms
64 bytes from 192.168.0.3: icmp_req=46 ttl=64 time=1.94 ms
64 bytes from 192.168.0.3: icmp_req=47 ttl=64 time=2.02 ms
2->1: 3 seconds
64 bytes from 192.168.0.3: icmp_req=4 ttl=64 time=1.52 ms
64 bytes from 192.168.0.3: icmp_req=5 ttl=64 time=1.60 ms
64 bytes from 192.168.0.3: icmp_req=8 ttl=64 time=1.28 ms
64 bytes from 192.168.0.3: icmp_req=9 ttl=64 time=2.18 ms
1->2 (again): 7 seconds
64 bytes from 192.168.0.3: icmp_req=16 ttl=64 time=1.42 ms
64 bytes from 192.168.0.3: icmp_req=17 ttl=64 time=1.73 ms
64 bytes from 192.168.0.3: icmp_req=24 ttl=64 time=2.23 ms
64 bytes from 192.168.0.3: icmp_req=25 ttl=64 time=1.98 ms

New distant neighbor

ping 192.168.0.6
kill $(cat killmeMOBILE.pid) ; \
wirefilter --daemon -v num0_7.ctl:num0_2.ctl --pidfile killmeMOBILE.pid
kill $(cat killmeMOBILE.pid) ; \
wirefilter --daemon -v num0_7.ctl:num0_1.ctl --pidfile killmeMOBILE.pid
B.A.T.M.A.N. IV:
1->2: 11 seconds
64 bytes from 192.168.0.6: icmp_req=21 ttl=64 time=4.15 ms
64 bytes from 192.168.0.6: icmp_req=22 ttl=64 time=3.55 ms
64 bytes from 192.168.0.6: icmp_req=34 ttl=64 time=3.87 ms
64 bytes from 192.168.0.6: icmp_req=35 ttl=64 time=2.78 ms
2->1: 3 seconds
64 bytes from 192.168.0.6: icmp_req=42 ttl=64 time=4.29 ms
64 bytes from 192.168.0.6: icmp_req=43 ttl=64 time=1.31 ms
64 bytes from 192.168.0.6: icmp_req=44 ttl=64 time=1.91 ms
64 bytes from 192.168.0.6: icmp_req=47 ttl=64 time=3.68 ms
64 bytes from 192.168.0.6: icmp_req=48 ttl=64 time=3.57 ms
1->2: 11 seconds
64 bytes from 192.168.0.6: icmp_req=60 ttl=64 time=3.12 ms
64 bytes from 192.168.0.6: icmp_req=61 ttl=64 time=1.63 ms
64 bytes from 192.168.0.6: icmp_req=72 ttl=64 time=2.98 ms
64 bytes from 192.168.0.6: icmp_req=73 ttl=64 time=1.71 ms
B.A.T.M.A.N. V:
1->2: 6 seconds
64 bytes from 192.168.0.6: icmp_req=4 ttl=64 time=3.28 ms
64 bytes from 192.168.0.6: icmp_req=5 ttl=64 time=1.94 ms
64 bytes from 192.168.0.6: icmp_req=11 ttl=64 time=1.75 ms
64 bytes from 192.168.0.6: icmp_req=12 ttl=64 time=1.68 ms
2->1: 5 seconds
64 bytes from 192.168.0.6: icmp_req=25 ttl=64 time=3.01 ms
64 bytes from 192.168.0.6: icmp_req=26 ttl=64 time=2.09 ms
64 bytes from 192.168.0.6: icmp_req=31 ttl=64 time=2.48 ms
64 bytes from 192.168.0.6: icmp_req=32 ttl=64 time=2.10 ms
1->2: 5 seconds
64 bytes from 192.168.0.6: icmp_req=49 ttl=64 time=1.33 ms
64 bytes from 192.168.0.6: icmp_req=50 ttl=64 time=1.72 ms
64 bytes from 192.168.0.6: icmp_req=55 ttl=64 time=2.44 ms
64 bytes from 192.168.0.6: icmp_req=56 ttl=64 time=2.36 ms

Mobile Node

ping 192.168.0.6
kill $(cat killmeMOBILE.pid) ; \
wirefilter --daemon -v num0_7.ctl:num0_6.ctl --pidfile killmeMOBILE.pid
kill $(cat killmeMOBILE.pid) ; \
wirefilter --daemon -v num0_7.ctl:num0_5.ctl --pidfile killmeMOBILE.pid
kill $(cat killmeMOBILE.pid) ; \
wirefilter --daemon -v num0_7.ctl:num0_4.ctl --pidfile killmeMOBILE.pid
B.A.T.M.A.N. IV:
6->5: 12 seconds
64 bytes from 192.168.0.6: icmp_req=7 ttl=64 time=1.23 ms
64 bytes from 192.168.0.6: icmp_req=8 ttl=64 time=0.913 ms
64 bytes from 192.168.0.6: icmp_req=20 ttl=64 time=1.11 ms
64 bytes from 192.168.0.6: icmp_req=21 ttl=64 time=1.69 ms
5->4: 11 seconds
64 bytes from 192.168.0.6: icmp_req=29 ttl=64 time=1.74 ms
64 bytes from 192.168.0.6: icmp_req=30 ttl=64 time=1.74 ms
64 bytes from 192.168.0.6: icmp_req=41 ttl=64 time=3.14 ms
64 bytes from 192.168.0.6: icmp_req=42 ttl=64 time=2.05 ms
B.A.T.M.A.N. V:
6 -> 5: 6 seconds
64 bytes from 192.168.0.6: icmp_req=38 ttl=64 time=1.29 ms
64 bytes from 192.168.0.6: icmp_req=39 ttl=64 time=1.43 ms
64 bytes from 192.168.0.6: icmp_req=45 ttl=64 time=1.28 ms
64 bytes from 192.168.0.6: icmp_req=46 ttl=64 time=1.20 ms
5 -> 4: 6 seconds
64 bytes from 192.168.0.6: icmp_req=49 ttl=64 time=1.10 ms
64 bytes from 192.168.0.6: icmp_req=50 ttl=64 time=0.550 ms
64 bytes from 192.168.0.6: icmp_req=56 ttl=64 time=2.13 ms
64 bytes from 192.168.0.6: icmp_req=57 ttl=64 time=3.05 ms