Upgrading Ubiquiti UniFi Controller On Linux

I have used the Ubiquiti UniFi product since it first came out and have watched the evolution with excitement because I believe the AP/Controller concept is the future of indoor wireless.

Ubiquiti has done it in their usual fashion by making powerful products affordable and UniFi is no different. With UniFi, you need a UniFi controller in place to fully utilize the statistical and maintenance features that make it so different than anything else at this price point.

That being said, to truly get the controller cost down, you have to use Linux to avoid the Microsoft bloat and licensing costs. If you aren’t using Debian or Ubuntu and have decided to roll your own with some other flavor of Linux like Centos, upgrading the UniFi software may not be totally obvious from the documentation so I will help you out.

Assuming you are running Centos. First, everything should be living in /usr/lib/UniFi. That directory should look like this:

The important directory is the data directory, everything else is installed with the upgrade. Therefore, make a backup of the data directory however you wish, but I recommend using tar like this:

tar -zcvf data.tar.gz /usr/lib/UniFi/data

This will create a tar.gz file in the /usr/lib/UniFi directory. Next you need to download the new UniFi binaries from Ubqiuiti. They are found HERE.

Because you have to accept the terms of their license agreement, using wget isn’t an option here so download to your laptop and then scp or ftp the zip file to your controller and place in the /usr/lib directory. Change the current UniFi directory to something else like this:

# mv UniFi UniFi-old

Then, unzip the new version in the directory /usr/lib. it should unzip itself as a directory named “UniFi”.

# cd /usr/lib # unzip UniFi.unix.zip

When the unzip operation is done, change to the newly created directory and rename the data directory like this:

# cd /usr/lib/UniFi # mv data data-dist

Then move your data tar file back to the proper directory:

# mv /usr/lib/data.tar.gz UniFi

Finally, restore your valuable data:

# tar -zxvf data.tar.gz

Unzip the file like this:

# tar -zxvf data.tar.gz

At this point you should be able to start the unifi controller and have an upgraded version with your old data still intact. Good luck!

Steve Discher

Steve Discher was born in Apple Valley, California and today makes his home in College Station, Texas with his wife and three children. He is a 1987 graduate of Texas A-M University and owns ISP Supplies, a wireless distribution company, and conducts MikroTik training classes. His hobbies include flying his Piper Cub and RV camping with his family.

Recent Posts

  • Finding an IP address with Wireshark using ARP requests

    Can’t remember a device’s IP Address? Address Resolution Protocol (ARP) requests can be used by Wireshark to get the IP address of an unknown host on your network. ARP is a broadcast request that’s meant to help the client machine …

  • Creating Trunk and Access Ports on MikroTik CRS3xx Series Switches

    The switch menu and configuration interface is significantly different on the CRS3xx versus the CRS1xx or CRS2xx series switches and if you are trying to configure VLANs, the process is totally different. Here is a quick HowTo for configuring VLANs …

  • Ubiquiti Unifi Video NVR Upgrade Fails

    Yesterday I got tired of the nagging “Update Available” on my Ubiquiti Video NVR so I went through the upgrade process in the web GUI. It failed with Error 400. I tried several times, several browsers, same error. I then …

See More News