Repository : ssh://git@open-mesh.org/doc
On branches: backup-redmine/2017-07-13,master
commit a68fd26af1b419b9f5ca1f35c045b17153cfde41 Author: Marek Lindner mareklindner@neomailbox.ch Date: Mon Jun 21 02:38:17 2010 +0000
doc: batman-adv/Wiki
a68fd26af1b419b9f5ca1f35c045b17153cfde41 batman-adv/Wiki.textile | 72 ++++++++++++++++++++----------------------------- 1 file changed, 29 insertions(+), 43 deletions(-)
diff --git a/batman-adv/Wiki.textile b/batman-adv/Wiki.textile index 14c59583..577f17db 100644 --- a/batman-adv/Wiki.textile +++ b/batman-adv/Wiki.textile @@ -1,43 +1,29 @@ -= batman-advanced = - -Batman-advanced is a new approach to wireless networking which -does no longer operate on the IP basis. Unlike the layer 3 batman-daemon, which exchanges -information using UDP packets and sets routing tables, batman-advanced operates -on ISO/OSI Layer 2 only and uses and routes (or better: bridges) Ethernet Frames. -It emulates a virtual network switch of all nodes participating. Therefore all nodes -appear to be link local, thus all higher operating protocols won't be affected -by any changes within the network. You can run almost any protocol above B.A.T.M.A.N.-Advanced, -prominent examples are: IPv4, IPv6, DHCP, IPX. - -=== Pros and Cons === -Pros: - * supports any Ethernet-capable protocol (IPv4, IPv6, ARP, DHCP ...) - * no manual IP assignment, just use DHCP - * easy integration of attached networks (no manual HNA fiddling), just put the bat0 in the bridge with your other devices. You can for example build a roaming network of Access Points with this technique. - * Not affected by your Firewall (but you can secure the payload traffic, of course) -Cons: - * ~~no gateway handling inside of B.A.T.M.A.N. (DHCP/IPv6 autoconf/static routes will work but B.A.T.M.A.N. won't help to choose the best gateway for you)~~ (the upcoming batman-adv 0.3 supports advanced gateway handling) -=== batctl (former battools) === - -Since the nodes participating in the B.A.T.M.A.N. Advanced switch are -completely transparent for all protocols above layer 2, we needed to build -our own diagnostic tool batctl. This tool contains a layer 2 version -of ping, traceroute and tcpdump. It also offers a configuration interface -for the kernel module as well as an integrated log reader. -Further information can be found in the enclosed README file. - -=== Userland vs Kernelland === - -The userland implementation of batman-advanced was a proof of concept implementation to verify that the concept is -working. Unfortunately, switching packets in userland is very expensive in terms of CPU cycles, as each packet has to be -read() and write() to the kernel and back, which limits the sustainable bandwidth especially on low-end devices. -To have good support for these devices as well, we implemented batman-adv as a kernel driver, which is now the -preferred version. It can be controlled via the /proc file system and works transparently. The userland remains unmaintained and has been removed from the subversion repository. - -=== Documentation === - -See the [wiki:UserDocs UserDocs] page. - -=== Get it === - -see the [wiki:Download] page \ No newline at end of file + += B.A.T.M.A.N. advanced = + +{{{ +#!div style="width: 46em; text-align: justify" + +B.A.T.M.A.N. advanced (often referenced as batman-adv) is an implementation of the B.A.T.M.A.N. routing protocol in form of a linux kernel module operating on layer 2. The rest of this document will explain the conceptual details and their implications. If you are looking for explanations how to use the module, please consult our [wiki:batman-adv-quick-start-guide quick start guide]. + +== Layer 2 ? == + +Most other wireless routing protocol implementations (e.g. the batman daemon) operate on layer 3 which means they exchange routing information by sending UDP packets and bring their routing decision into effect by manipulating the kernel routing table. Batman-adv operates entirely on ISO/OSI Layer 2 - not only the routing information is transported using raw ethernet frames but also the data traffic is handled by batman-adv. It encapsulates and forwards all traffic until it reaches the destination, hence emulating a virtual network switch of all nodes participating. Therefore all nodes appear to be link local and unaware of the network's topology as well as unaffected by any network changes. + +This design bears some interesting characteristics: + * network-layer agnostic - you can run whatever you wish on top of batman-adv: IPv4, IPv6, DHCP, IPX .. + * nodes can participate in a mesh without having an IP + * easy integration of non-mesh (mobile) clients (no manual HNA fiddling required) + * roaming of non-mesh clients + * optimizing the data flow through the mesh (e.g. interface alternating, multicast, forward error correction, etc) + +== A kernel module ? == + +A layer 2 routing protocol also has to handle the data traffic because usually one can't route/forward ethernet packets. Processing packets in userland is very expensive in terms of CPU cycles, as each packet has to be read() and write() to the kernel and back, which limits the sustainable bandwidth especially on low-end devices. To have good support for these devices as well, we implemented batman-adv as a kernel driver. It introduces a negligible packet processing overhead even under a high load. + + +== batctl ? == + +To still have a handy tool to configure & debug the batman-adv kernel module, the batctl tool was developed. It offers a convenient interface to all the module's settings as well as status information. It also contains a layer 2 version of ping, traceroute and tcpdump, since the virtual network switch is completely transparent for all protocols above layer 2. + +}}}