The BeagleBone Network Multitool (beaglenmt) is a lightweight buildroot-based, X11-free, networking-centric, IPv6-ready distribution for the BeagleBone platform. beaglenmt includes an assortment of networking tools so that it may be used as a secure proxy or for various networking experiments:
- Networking Management: iproute2, iptables, ebtables, brctl, tunctl, wvdial
- Networking Diagnostics: mtr, tcpdump / libpcap, wireshark, nmap, kismet, whois, arp, arping, iftop, bmon, iperf, ngrep, ethtool, ndisc6, rdisc6, ping6, traceroute6
- Networking Applications: curl, links, socat, netcat, rsync, sshfs, rtorrent
- Security / Tunneling: openssh, openvpn, openssl, gnupg, stunnel
- Scripting: python2, lua5.2
- Filesystem: ext2/3/4, fat, ntfs
- Misc: git, tmux, pv, htop, powertop, pstree, iostat, netstat, memstat
- Plus many standard Unix utilities provided by Busybox
- USB Wireless LAN support
- Linux kernel version 3.12.10
- Buildroot version 2014.11
The resulting system is 135MB in size. Follow the instructions below to build it.
The configuration files and instructions to build beaglenmt are available here: https://gist.github.com/vsergeev/abd5a75b75b2938586d9
Insert the SD card, press and hold the boot button, apply power to the BeagleBone, then release the boot button.
beaglenmt is accessible from first boot via the serial port, ethernet (DHCP), and usbnet (static IP
The first boot may take a few extra seconds as sshd automatically generates server keypairs for SSH.
Start your favorite serial port terminal attached to the console serial port device (e.g.
/dev/ttyUSB0). In the case of a BeagleBone Black, connect a USB to UART cable (e.g. TTL-232R-3V3) to the console UART header in advance (black pin towards ethernet port). Observe the boot in your serial port terminal.
beaglenmt brings up the
eth0 interface with DHCP on boot. Ethernet connectivity must be present at boot for the DHCP client to obtain a lease. Once the BeagleBone is online, connect to it over SSH with user
beaglenmt loads the USB Ethernet Gadget module on boot to enable the
usb0 interface, and brings up the interface with the static IP address
10.0.0.123 and network mask
255.255.255.0. To connect to the BeagleBone over usbnet, bring up your host’s
usb0 interface (or whichever name it takes on your system) with a static IP address on the same subnetwork.
host $ sudo ifconfig usb0 up 10.0.0.5/24 host $ ping 10.0.0.123 PING 10.0.0.123 (10.0.0.123) 56(84) bytes of data. 64 bytes from 10.0.0.123: icmp_seq=1 ttl=64 time=0.595 ms 64 bytes from 10.0.0.123: icmp_seq=2 ttl=64 time=0.475 ms 64 bytes from 10.0.0.123: icmp_seq=3 ttl=64 time=0.407 ms ^C --- 10.0.0.123 ping statistics --- 3 packets transmitted, 3 received, 0% packet loss, time 1999ms rtt min/avg/max/mdev = 0.407/0.492/0.595/0.079 ms host $
Connect to the BeagleBone at IP address
10.0.0.123 over SSH with user
Login with username
- Add a normal user with a password, and add the user to the
wheelgroup for sudo permission.
# adduser foobar # addgroup foobar wheel
Adjust your timezone in /etc/TZ, if you downloaded a pre-built image.
ssh-copy-idon your host machine to copy over your host user’s SSH public key to the beaglebone.
host $ ssh-copy-id foobar@beagleboneip
- Disable root login in
/etc/sshd_configby commenting out “PermitRootLogin” and adjust the other settings as desired.