Overview
Readers will learn how to install the UniFi package on the UniFi-Video NVR.
This is not as simple as “apt-get install unifi”, however. The NVR, by default, uses LVM and has a very spacious volume setup which is where all of the recordings are saved. Installing installing UniFi outside of this volume will result in a loss of space on other volumes that are important to the system.
![]() |
Steps
Note: Before proceeding to the steps, ‘vi’ is the default text editor on the NVR. If you are a Linux beginner or not comfortable with vi, it’s recommended you install ‘nano’ as your text editor for step #4. You can do this by:
apt-get update; apt-get install nano
Then for step #4, you would issue nano /etc/apt/sources.list
To install UniFi on the NVR:
- SSH in to the NVR (default credentials are root/ubnt)
- Issue mkdir /srv/unifi – This will make the directory where UniFi will be installed
- Issue ln -s /srv/unifi /var/lib/unifi – This will make the install process place the UniFi files in /srv path which is the larger volume to store the UniFi-Video recordings
- Use your favorite text editor to modify /etc/apt/sources.list – This will edit the sources.list file where apt searches for available packages
- Scroll to the bottom, put a couple of new blank lines in and add the following regardless of what UniFi version you want:
# Ubiquiti UniFi deb http://downloads-distro.mongodb.org/repo/debian-sysvinit dist 10gen
- If you want the version 4 controller, add the following on a new line in that same file:
deb http://www.ubnt.com/downloads/unifi/debian stable ubiquiti
- If you want the version 3 controller, add the following on a new line in that same file:
deb http://www.ubnt.com/downloads/unifi/debian oldstable ubiquiti
- Save and exit the file.
- Issue the following command to get the GPG keys:
apt-key adv --keyserver keyserver.ubuntu.com --recv 06E85760C0A52C50; apt-key adv --keyserver keyserver.ubuntu.com --recv 9ECBEC467F0CEB10
- Issue apt-get update – Updates the apt cache to include the packages at the above lines
- Issue
apt-get install unifi; apt-get install -f; apt-get clean
to install the UniFi controller
Notes:
- If you factory default your NVR, these changes will not persist, you’ll need to repeat the process
- After UniFi is done installing, it may take a minute or two to be available at https://[your NVR IP address]:8443 . This is because it’s creating the necessary database structure.