How to install Unifi Controller on Raspberry/Orange Pi

The target platform for this tutorial is an Orange Pi Plus 2E.


Be aware that unifi will run its bundled instance of mongo db. This might conflict with any existing instance. I disabled mine via:

systemctl stop mongodb
systemctl disable mongodb

Besides this, it requires Java, so I installed oracle java8 via

apt-get install oracle-java8-installer
Others might need
apt-get install oracle-java8-jdk

Besides many different ports, especially these once are required (check with netstat -lnp):

8080, 8443, 8880


1.  Add Unifi repository

echo 'deb stable ubiquiti' | sudo tee -a /etc/apt/sources.list.d/100-ubnt.list > /dev/null
sudo wget -O /etc/apt/trusted.gpg.d/unifi-repo.gpg
sudo apt-get update
2. Install unifi package
apt-get install unifi

3. Access the web interface

Others might need


  • check your logfile under /var/log/unifi/server.log AND /var/log/unifi/mongod.log
  • whenever you start unifi via /etc/init.d/unifi start check first if no java and mongo processes are still running

How to repair after cancelled upgrade

When I ran "apt update" followed by "apt dist-upgrade" the unifi package update asked if i had a backup: I said no, it cancelled the unifi update, and left me with a broken installation. Thanks to user jason0

1.  Fix the broken start of mongod by creating a symlink 
ln -s /usr/bin/mongod /usr/lib/unifi/bin/mongod
2. Check your /var/log/unifi/server.log and locate the version of your installation
[2019-03-28 14:02:42,248] <launcher> INFO  system - UniFi 5.8.24 (build atag_5.8.24_11016 - release) is starte

3. Download the deb package (here 5.8.24)


4. Extract the deb file

ar -x unifi_sysvinit_all.deb

5. Extract the data file

tar -xf data.tar.xz

6. Copy the content of the webapp folder

cp -Rv ./usr/lib/unifi/webapps/ /usr/lib/unifi/webapps/

Kill all java processes and restart unifi!