Adding OSPF support to Ubiquiti devices
Although Ubiquiti devices don't ship with OSPF support, Ubiquiti do provide a firmware SDK for building custom firmware with additional software of your choosing. Ubiquiti firmware is based on OpenWrt, and consequently there are a lot of software packages available to install, including both BIRD and Zebra.
This guide focuses on building a custom Ubiquiti Airmax firmware with BIRD integrated.
Requirements:
- A working Linux system or virtual machine with build tools installed.
- Some Unix knowledge (editing/patching files, building software, copying files).
- Ubiquiti Airmax SDK v5.3.
- My patch.
Extract and patch SDK
Download the SDK tarball and patch file, placing them both into the same directory.
tar xjf SDK.UBNT.v5.3.tar.bz2 unzip ubnt-5.3-bird-1.2.5.zip mv SDK.UBNT.v5.3 SDK.UBNT.v5.3.ospf cd SDK.UBNT.v5.3.ospf patch -p1 <../ubnt-5.3-bird-1.2.5.diff
All the above commands should complete with no errors.
Build firmware
To build the firmware your system will need internet access so that the build tools can fetch package data.
From within the SDK.UBNT.v5.3.ospf directory:
cd openwrt make
The build will take a long time even on fast hardware. Go make a sandwich. :)
When it completes, there should be a firmware image in the bin directory:
cd bin ls -l XM* -rw-r--r-- 1 aragon aragon 6932789 Jan 29 14:38 XM.v5.3.ospf.7782.110129.1434.bin
Load that firmware onto your device using the update option in the device's web interface.
Using BIRD
Although you've loaded BIRD onto your Ubiquiti device, there is no pretty GUI to it on the Ubiquiti user interface. BIRD is a Unix daemon, and unless you want to write your own web interface to it, you have to configure and use it via the command line. SSH into your device and start by creating /etc/persistent/bird4.conf. Please see the BIRD User Guide for instructions on configuring and using BIRD.
Once your configuration is done, try start BIRD on your device:
bird4.init start
For more usage information and examples, have a look at how it's used in Hout Bay.