Upgrading the Ubiquiti UniFi Controller Software on Centos

I recently completed a deployment of several Ubiquiti UniFi UAP-AC-PRO access points and so far I’ve been very impressed with their performance.

One of the best things about Ubuqiti is that the UniFi controller software is completely free.

Ubiquiti UniFi

Ubiquiti provides a Linux package for Debian /Ubuntu but in order to install UniFi on Centos or any other non Debian based distro you must use their Linux DIY package.

The DIY version of the software isn’t very well documented and has a couple of caveats.

  1. The auto update feature of the UniFi controller software does not work.  
  2. The configuration backup and restore feature does not work.

Since Ubiquiti bundles new versions of the access point firmware with the UniFi controller software it is necessary to upgrade UniFi in order to deploy new AP firmware versions.

This creates a slightly annoying issue since the UniFi software can’t be automatically upgraded.

Furthering frustrations the Linux DIY package doesn’t really provide any useful instructions on the proper way to perform this upgrade.

I decided to share the procedure I’ve been using to upgrade the software to help out the other Centos Linux users out there.

These steps have been tested on Centos 7.0 but they should work for most other distros too.  If you have UniFi installed somewhere besides /opt then you will need to change the paths in the commands below.

 Step 1: Stop the UniFi service

The UniFi service must be stopped before you can proceed with the upgrade.

service unifi stop

Step 2: Backup the current configuration

tar -zcvf /root/backup.tar.gz /opt/UniFi/data/

You may see a message that one of the journal files changed while being read, this is normal and can be ignored.

Step 3: Download the new UniFi package

The current release version of the UniFi DIY package is 5.4.11.

Ubiquiti recently dropped support of the DIY packages.  They have stopped posting the download links but the files are still present.  To find the links to the new versions of the DIY packages you need to register for access to the beta forums.  The new release posts contain the download links for the DIY packages.

wget https://www.ubnt.com/downloads/unifi/5.4.11-6cbeae59e7/UniFi.unix.zip /root/UniFi.unix.zip

Take a look at the Ubiquiti forums for more information about the lack of support for DIY packages.  Also, please vote for the feature request to provide officially supported RPM packages for the UniFi software.

Step 4: Unzip the new version and fix the ownership

unzip -qo /root/UniFi.unix.zip -d /opt
chown -R ubnt:ubnt /opt/UniFi

Step 5: Restore the configuration backup

tar -xzvf backup.tar.gz -C /opt/UniFi/data/

Step 6: Start the UniFi service

service unifi start

Verifying the Upgrade

To verify the new version was properly installed log into the UniFi web interface and go to the Settings \ Maintenance menu.  The version is indicated under the server information section of the maintenance page.

UniFi Controller Settings Maintenance Menu

Sam Kear

Sam graduated from the University of Missouri - Kansas City with a bachelors degree in Information Technology. Currently he works as a network analyst for an algorithmic trading firm. Sam enjoys the challenge of troubleshooting complex problems and is constantly experimenting with new technologies.

7 thoughts on “Upgrading the Ubiquiti UniFi Controller Software on Centos

  1. Nize. Was just looking for something like this to update my cloud controller.
    Now I just need to find a way to setup Remote user VPN authentication on that same cloud controller to have a single point of managing user access. Any thoughts?

  2. Hi Sam. I just used your instructions to upgrade to UniFi Controller version 5.0.6 on a Centos 7 box. It worked flawlessly. Thanks.

  3. Hi Sam,

    Great instructions. Did not work the first time. There already was a UniFi.unix.zip file so the new downloaded had a different name. After that, all good…

  4. Thanks. I have been looking for more documentation on upgrading my centos7 unifi controller. I found the documentation to standing it underwhelming. So it is nice to find this simple upgrading KB.

Leave a Reply

Your email address will not be published. Required fields are marked *