This will now be the third part of this series of posts on my blog which cover development using Raspberry Pi, Raspbian and Batman-adv. For those who may have missed the first two, check out:
The part covers the basics on getting IPv4 to work with Batman-adv. At first, when reading the documentation I thought that a DHCP server had to be physically installed on a device running batman, but I now understand that isn't the case.
It's pretty simple to get it working now that i've finally gotten my head around that basic fact. If you've followed the first two guides, you will have a devices which his already bridged and meshing. To get the device to pickup a DHCP IPv4 address, we need to follow the below steps:
1: Start by modifying the interfaces file: sudo nano /etc/network/interfaces
2: Look for the following line: iface eth0 inet dhcp
3: If you have setup the mesh-bridge interface, add the following: iface mesh-bridge inet dhcp
or, if you have bat0 and didn't do the bridging, add: iface bat0 inet dhcp
4: save the file and exit
5: Restart the network: sudo /etc/init.d/networking restart
And that's it - as long as there is something issuing DHCP addresses connected to one of the interfaces (from a node which is bridged and has eth0 plugged in for example) you should now pickup a DHCP address.
Hopefully that will help someone out there. My blogging skills are poor and I never really planned for this to be a 'three part guide' as it were. If anyone reading this has issues understanding then leave a comment and i'll try and help you out.
I've gotten a few model A pi's today, so look forward to using them with the above to create wireless nodes for various projects.
No comments:
Post a Comment