As I was using a Miraki AP (MR12) and the license was about to end I started looking for a new AP. The Web GUI for Meraki is really nice, but the MR12 is slow and already 3 years old. Also the licenses are pretty expensive so I decided it is time to upgrade. When searching I found the Ubiquiti UniFi AC AP Pro as a good solution. I noticed there is a controller software required to configure the AP. Also I found some tutorials to add the Controller software to my RPi 3 running as a VPN server (OpenVPN) and local DNS server (Bind).
Well let’s install the Unifi software! This is how I did add / install the software.
Note: I did follow some steps from this tutorial but added some extra info to get it working on my home setup: http://www.lowefamily.com.au/2016/06/02/installing-ubiquiti-unifi-controller-5-on-raspberry-pi/3/
Update your RPi system
First of all make sure your Raspberry Pi is up-to-date.
sudo apt-get update && sudo apt-get upgrade -y
After the packages are updated also run the latest firmware for your RPi
This can take some time so please wait and reboot your system after it is done (just run “reboot”)
Install Unifi Controller Software
Now let’s add the Unifi controller software. First we need to make sure to add the Repository to the RPi so we can use apt-get.
echo ‘deb http://www.ubnt.com/downloads/unifi/debian unifi5 ubiquiti’ | sudo tee -a /etc/apt/sources.list.d/ubnt.list > /dev/null
sudo apt-key adv –keyserver keyserver.ubuntu.com –recv C0A52C50
sudo apt-get update
After we have added the Repository we can start the installation. Keep in mind we just updated apt-get already so running the install is sufficient. This will install the Unifi software including JAVA7. If you need / want JAVA8, i’m sorry out of scope here 🙂
sudo apt-get install unifi -y
Next reboot your system again 🙂
When trying to reach http://rpi-hostname:8443 i was not able to get an webinterface, this was due to the fact i’m running IPtables on my RPi. So let’s add the TCP port to allow it. Also you have some other ports to allow like 8080 with the inform URL. See for port info: https://help.ubnt.com/hc/en-us/articles/218506997-UniFi-Ports-Used
Note: Change eth0 to your interface nic where you are connecting to!
sudo iptables -A INPUT -i eth0 -p tcp –dport 8443 -j ACCEPT
sudo iptables -A INPUT -i eth0 -p tcp –dport 8080 -j ACCEPT
sudo iptables -A INPUT -i eth0 -p tcp –dport 8880 -j ACCEPT
sudo iptables -A INPUT -i eth0 -p tcp –dport 8843 -j ACCEPT
Don’t forget to save the rules 🙂
When done you can visit the webinterface to start configuring your Unifi AP. Browse to http://rpi-hostname:8443 and start configuring!
Configure Unifi Controller
Now we have a running Controller on our Raspberry Pi 3 it’s time to configure your AP.
The controller will detect your new AP and you can follow the On-Screen instructions to configure your AP.