Table of Contents

Daves Mesh Network Experiments

Various records of networking experiments

Setting up dhcp server

Used for example to ssh into a raspberry pi or beagleboard from a laptop with no router present.

apt-get install isc-dhcp-server

Create /etc/dhcp/dhcpd.conf:

ddns-update-style none;
option domain-name "example.org";
option domain-name-servers ns1.example.org, ns2.example.org;
default-lease-time 600;
max-lease-time 7200;

authoritative;

subnet 192.168.0.0 netmask 255.255.255.0 {
        ## dhcp start  and end IP range ##
        range 192.168.0.100 192.168.0.200;
        option subnet-mask 255.255.255.0;     ## subnet
        option broadcast-address 192.168.0.255; ## broadcast
        option routers 192.168.0.1; ## router IP

        host eth0 {
                hardware ethernet 70:5A:B6:0B:1C:67;
                fixed-address 192.168.0.1;
        }

}
sudo service isc-dhcp-server start

Set ip address of machine to fixed:

sudo ifconfig eth0 192.168.0.1

Also sanity check ip addresses via:

route -n

Plug in cables, and scan:

sudo arp-scan --interface=eth0 192.168.0.0/24

Running an ad-hoc wireless network on the raspberry pi

ifconfig wlan0 down
iwconfig  wlan0 channel 4
iwconfig  wlan0 mode ad-hoc
iwconfig  wlan0 essid 'raspberry pi ad-hoc'
iwconfig  wlan0 key password
ifconfig  wlan0 192.168.2.1

https://github.com/jech/babeld