Self Hosted UniFi Network Application Controller Install Tutorial
Ғылым және технология
Official Documentation UniFi Network - Updating Third-Party, non-Console UniFi Network Applications (Linux - Advanced)
help.ui.com/hc/en-us/articles...
My GitHub script
github.com/lawrencesystems/yo...
UniFi Network Application 7.3.76
community.ui.com/releases/Uni...
Mongo Forum post Mentioned in Video
www.mongodb.com/community/for...
Connecting With Us
---------------------------------------------------
+ Hire Us For A Project: lawrencesystems.com/hire-us/
+ Tom Twitter 🐦 / tomlawrencetech
+ Our Web Site www.lawrencesystems.com/
+ Our Forums forums.lawrencesystems.com/
+ Instagram / lawrencesystems
+ Facebook / lawrencesystems
+ GitHub github.com/lawrencesystems/
+ Discord / discord
Lawrence Systems Shirts and Swag
---------------------------------------------------
►👕 lawrence.video/swag
AFFILIATES & REFERRAL LINKS
---------------------------------------------------
Amazon Affiliate Store
🛒 www.amazon.com/shop/lawrences...
UniFi Affiliate Link
🛒 store.ui.com?a_aid=LTS
All Of Our Affiliates that help us out and can get you discounts!
🛒 lawrencesystems.com/partners-...
Gear we use on Kit
🛒 kit.co/lawrencesystems
Use OfferCode LTSERVICES to get 10% off your order at
🛒 lawrence.video/techsupplydirect
Digital Ocean Offer Code
🛒 m.do.co/c/85de8d181725
HostiFi UniFi Cloud Hosting Service
🛒 hostifi.net/?via=lawrencesystems
Protect you privacy with a VPN from Private Internet Access
🛒 www.privateinternetaccess.com...
Patreon
💰 / lawrencesystems
⏱️ Timestamps ⏱️
00:00 UniFi Network Application Installer 7.3.76
02:09 Java 11 Required
02:31 Self Hosted Controll Documentation
02:48 Why Ubuntu 20.04 LTSb
03:25 Dependencies & Requirements
04:03 How To Install
06:29 Restore From Backup
07:04 Web UI Setup
#unifi #networking #ubiquiti
Пікірлер: 149
Official Documentation UniFi Network - Updating Third-Party, non-Console UniFi Network Applications (Linux - Advanced) help.ui.com/hc/en-us/articles/220066768-UniFi-How-to-Install-and-Update-via-APT-on-Debian-or-Ubuntu My GitHub script github.com/lawrencesystems/youtubedemos/blob/main/Basic_UniFi_Install.sh UniFi Network Application 7.3.76 community.ui.com/releases/UniFi-Network-Application-7-3-76/85c75fc7-3e0f-4e99-aa90-7068af4f1141 Mongo Forum post Mentioned in Video www.mongodb.com/community/forums/t/installing-mongodb-over-ubuntu-22-04/159931/40 ⏱ Timestamps ⏱ 00:00 ▶ UniFi Network Application Installer 7.3.76 02:09 ▶ Java 11 Required 02:31 ▶ Self Hosted Controll Documentation 02:48 ▶ Why Ubuntu 20.04 LTSb 03:25 ▶ Dependencies & Requirements 04:03 ▶ How To Install 06:29 ▶ Restore From Backup 07:04 ▶ Web UI Setup #unifi #networking #ubiquiti
@maximusg88
Жыл бұрын
Thanks man! Does this work with the Raspberry Pi or would I need to adjust the script to download ARM versions?
@JPEaglesandKatz
2 ай бұрын
Unfortunately does not work anymore... And neither does the same outdated one on the unifi site.
@LAWRENCESYSTEMS
2 ай бұрын
@@JPEaglesandKatz kzread.info/dash/bejne/foRoxqulaLzFiNo.htmlsi=nKV9GMoahbaZ00io
Ubiquiti should have official containers, that way you can run it on wherever you want without worrying about package availability on distros.
@skorpion1298
Жыл бұрын
Just use Glenn R. Script. Works on every Linux system.
@Max-jv3yg
Жыл бұрын
Making it easy would cut into their CloudKey and DreamMachine sales...
@TheShigeruJP
Жыл бұрын
@@Max-jv3yg maybe. there are still people that like the simplicity of a device that does it all for you
@ChrisDraussen
Жыл бұрын
@@skorpion1298 I used it on a PI Desktop distro. Which is basically Debian 10 at the moment. There was a serious error and I went with Ubuntu then. So far with no flaws.
I cannot tell you how timely this is! Looking forward to another video for setting up a multi-site config.
Thank you for this video. I was able to setup my own config in a few minutes based on it. It was definitely a time saver. Other tutorials are a mess or outdated.
I am new to Ubiquiti and this was very helpful. Thank you
Tom, this was a great video. Thank you for putting this together, I was able to follow it and restore a backup of my older controller with ease.
@LAWRENCESYSTEMS
Жыл бұрын
Glad it helped!
Great setup, checking it out as we speak. I restored a backup. Just a FYI for anyone doing it... Took about 5 minutes to start seeing my APs. Not sure why, but the adopted slowly. Big thanks !
Thank you so much for this video. With your help I was able to get it up and running on an atomic pi that I've had siting around that wasn't being used for anything. It's a nice low power SBC that seems to run it without issues.
I was just looking to migrate from a cloud key to self hosted and sure enough Tom has me covered re install 👍 Migrating to a VM on ESXi 8 or XCP-NG and selling off CK. Unifi - wireless Cisco CBS switches :)
Yes please make a multi-hosted controller! I would love to see you're process!
I moved to the linuxserver docker, while it is unofficial that group has a large number of very reliable dockers, and the nice thing about using it is that they keep the mongo and java dependencies correct with each release. Side note on 7.3 my network map works again.
@abee4447
Жыл бұрын
They update those dockers slowly compared to unifi releases though
@YKSGuy
Жыл бұрын
@@abee4447 having used several broken unfii releases I prefer they are slower.
@slipknottin
Жыл бұрын
Yep I’m using the Linuxserver docker as well. Have never had a problem with it.
@bjohnson8949
Жыл бұрын
@@abee4447 It normally a few days behind releases and its stable and just works so nicely! I highly recommend giving it a try.
This works perfectly! Thanks! Had to install gnupg2 packege for it to work on my proxmox ubuntu 20.04 container but other than that, this script is flawless.
Worked a treat, thank you.
Always use there migration docs great video 👍
Thank you for this video! It helps me a lot in a new project in my job here in Brazil! Muito obrigado!!!!!
Thanks so much! This was so helpful.
I just replaced my first generation Cloud Key with a VM similar to what you did. I went debian 11 and a script, but I think I'll be doing what you did with ubuntu 20.04 just to be safe. that hold java 11 part may be very important. Saving this video just in case.
I used this tutorial to setup a unifi controller on an unraid vm. thank you
Long time follower and viewer. All of your work is done so well and is critical in all the right places. Figured a good word goes a way. Hope you continue to enjoy the business as much as we all do :)
@LAWRENCESYSTEMS
Жыл бұрын
A good word does go a long way, thank you!
Thanks for this. I really struggled getting this installed on Debian. I think it was because of Java 8, it failed to start the service. but that install looked much smoother. I have a large install of 200 devices (APs and cameras) or so. Been trying to get the DHCP option for the UniFi IP to work to make my life easier, but can't get it going. More tinkering needed. Thanks
Awesome walkthrough Tom! Would love to see the unifi7 walkthrough for a TrueNAS Core jail.
@LAWRENCESYSTEMS
Жыл бұрын
TrueNAS Core jails are dying so I am planning on doing any videos for them.
Thank you for this video!
@LAWRENCESYSTEMS
Жыл бұрын
Glad it was helpful!
Love your videos. They help me a lot. Just wanted to let you know that the version in the thumbnail has the wrong version number. It says 7.3.67 - should have been 7.3.76 😀
@LAWRENCESYSTEMS
Жыл бұрын
Thanks, I replaced it with the correct one (not sure how log it will take KZread to propagate the change.
@miped0707
Жыл бұрын
@@LAWRENCESYSTEMS Anytime! I'm already seeing the updated thumbnail :-) Have a great day and weekend
This is exactly how I like to host my controller. I do not like dealing with the docker containers because I have to keep forcing my access points to adopt randomly. Some people may not agree, but I believe hosting UniFi natively on 20.04 with mongo and Java is way more stable than Docker. Thanks again.
@bjohnson8949
Жыл бұрын
You just have to create your container with a static IP and you will never have issues at all connecting to it.
@arubial1229
Жыл бұрын
You have something wrong in your Docker container setup. I’ve used it for years without any issues.
@kevinhilton8683
10 ай бұрын
@@bjohnson8949 Do you have a link exactly how to do this? A static IP on the host network or docker network? MACVLAN?
Thanks for straight forward instructions. Will this work on Digital Ocean droplets?
Hey Tom, I followed these instructions on my Raspberry pi but come up with errors, have you had this latest version work on a pi?
Thank you for this. I'm about to set up my first Unifi AP, and this is exactly what I needed. :) It's been about 8 months. Is the situation still the same with MongoDB/the latest Ubuntu LTS?
the only thing i would include in this would be the Lets Encrypt - i see your previous controller you downloaded the backup from was encrypted with a proper SSL. it would be nice to include that in your setup. but as you said in the beginning you did mention you were going from ubiquiti's Documentation
@LAWRENCESYSTEMS
Жыл бұрын
I don't bother with a Let's Encrypt cert on the controller, I do it with a reverse proxy, specifically HAProxy.
Thanks
The only script I use to install UniFi on my Raspberry PI running 64-bit Raspberry OS is the script from Glenn over on the Ubiquity forums. I believe he is also a Ubiquity employee.
@EvilCob
Жыл бұрын
Could you link to that script please?
Sadly its using an EOL version of Mongodb 3.6! Why doesn't Unifi update their dependencies??????
Tried and tried on a pi with Debian 12. The Mongo DB was the worst. Gave up after 8 hours. Ran the script and it was done
Good evening Lawrence. Thank you for the cool video it's much appreciated as at some point I want to move over to the unified ecosystem for a lot of stuff in my home lab and house. I did have a quick question though in regards to some recent news. I've heard that LastPass had another data breach the other day and I'm to the point where I think I would rather try to host my own password management system that I can access both on my phone as well as in my house. I was wondering if by chance you can go over some of the more popular self hosted options that are out there as well as maybe doing a couple of Updated install guides for their newest release of their software by chance. Thank you to you and your team for all the information packed videos it definitely makes doing a lot of this stuff a lot easier and more enjoyable. If I don't get a chance to talk to you again before Christmas I hope you and all your crew have a happy and safe Christmas.
@LAWRENCESYSTEMS
Жыл бұрын
I know there are others, but we use Bitwarden kzread.info/dash/bejne/ZY1ssZKwqbzZmbQ.html
@RunicGamingYT
Жыл бұрын
@@LAWRENCESYSTEMS thank you, I appreciate it.
@jonathan.sullivan
Жыл бұрын
@@RunicGamingYT VaultWarden is the lighter version of BW
@RunicGamingYT
Жыл бұрын
@@jonathan.sullivan thank you, I will look into that as a possible option as well.
Would you cover the default configuration for setting up the Unifi Network Application running on a Windows 10 Virtual machine, the use of Adoptium Eclipse Java and the firewall rules that allow access to java.exe and javaw.exe. I could be misunderstanding, but this seems like a very insecure configuration with a non-standard version of java 11 being recommended by Ubiquiti.
Hi Tom, have you tried to run Omada and Unifi controller on the same server?
Glenn script is from Glenn who's emplyed at Ubiquity.
How can we install this on a different network than the default vlan? If I try to move the host out of the mgmt vlan the switches go offline and have to be factory reset. They wont pass any traffic including DHCP
hi lawrence, ive upgraded to this firmware on a windows 10 vm, now although the wifi is fine, the unifi ac pro access points are showing offline, have i broken something
After watching Tom. Now waiting for Chris from Crosstalk Solutions to upload his definitive guide.
Did you back up and restore on the same controller version? How would I back up my current controller and restore if the version isn’t the same ?
@LAWRENCESYSTEMS
Жыл бұрын
You can restore from a slightly older version to the new version
Had to rebuild my home controller a few months back after the SD card died in my Pi (thankfully I'd grabbed a routine back up days earlier). Decided to move it to a VM on xcpng and since Stretch was now EOL went with Buster... and then had to go back to Stretch for Java 8 😢 Not a fan of Frankensteining packages from oldstable. Hopefully mongodb isn't an issue (other than being an old version) and I can switch to the Buster VM at the weekend. Any reasons not to update unifi to the Java 11 version? Thanks 👍
@LAWRENCESYSTEMS
Жыл бұрын
The latest 7.3.X requires Java 11
Hey Tom do you have any videos on building a home server for running things like unifi controller and well home entertainment etc?
@LAWRENCESYSTEMS
Жыл бұрын
Check our Homelab Show podcast and XCP-NG videos kzread.info/dash/bejne/o2GerdVvYsWcc9I.html
On a default ubu2004 LTS LXC container in proxmox gnupg is required, so one must add it ad the beginning of the script
@CircuitNinja
Жыл бұрын
Thank you my guy, you just saved me a headache
I have some Unifi and Edge switches at work. I've been trying to learn how to manage them and get familiar, and generally anytime I ask the internet how to do something with them, 50% of the replies tell me that Ubiquiti is garbage and that I should get rid of it all and buy better equipment lol.
It failed for me and got an error about unmet dependencies: mongodb-org-server: Depends: ibssl1.0.0 (>= 1.0.2 beta3) but is not installable. Any suggestions? This is a new VM Ubuntu 20.04 Server LTS, update/upgrade commands run. (I'm still new to Linux CLI)
@ediw4483
Жыл бұрын
I had pretty much the same problem : (
@miravida9778
9 ай бұрын
were you able to get it fix? I have the same issues.
How about an updated script? There are issues with MongoDB Server keys being expired. Would make a good update to this video....thanks
Can I use this guide on a raspberry pi 4?
The official docs for Ubuntu and Debian still reference version of the operating systems which are EOL - with Ubuntu 18.04 EOL next year. Then there is Mongo - Ubiquiti seem to be avoiding the changes to Mongo licensing by using (possibly) an older version without the need for commercial licensing. Mongo 4.2 is currently the oldest release with isn't EOL. Any other version I'd expect to be exploitable and dangerous, the biggest concern would be it's dependency on OpenSSL. Would be great if someone with a substantial audience could ask Ubiquiti why the continue to recommend operating systems and software with is EOL and should be considered compromised. (FYI totally doable with LSX Ubuntu Jammy container by recompiling the src deb from Ubuntu bionic which at least helps with any OpenSSL issues)
@LAWRENCESYSTEMS
Жыл бұрын
They don't listen to me or anyone else when it comes to their choices around versions.
Great video, I am new to ubiquiti, does this effectively replace devices such as the Dream Machine Pro or similar devices? I would like to run 4 unifi access points without the need to buy a Dream Machine pro, I am already running pfsense and want to stay on pfsense
@LAWRENCESYSTEMS
Жыл бұрын
Yes
So if I have a cloud hosted controller and a switch, does the switch need to be a Layer 3 switch to host the local DNS if the WAN goes down? I’m thinking of using a cloud solution as a failover for my UDM SE if it ever fails, so that I don’t have a high value asset being the single point of failure (i know the switch can also fail but a Layer 2 switch is much cheaper than a layer 3 one, hence the question)
@LAWRENCESYSTEMS
Жыл бұрын
Not clear on the question because switches don't host DNS.
@tazerpie
Жыл бұрын
@@LAWRENCESYSTEMSoops meant DHCP 🙄
Hello, Thanks for making the good content always. In our case, we have Ubuntu 22.04 and when we go for Unifi upgrade it gives mongodb dependency error. Could you please help us a give a good way to solve this issue? Current Unifi version: 7.4.162 Current Mongodb version: 3.4
I had bought a G4 instant camera thinking I could self host it. I got pretty much to where this video ends but I can’t seem to figure out how to connect (or adopt in unifi terms) to the camera to use it. Once you have the network (the point of this video) how do you connect devices? I was trying to run it in docker on my RasPi and then tried on my Mac just to see if it made a difference but still no luck.
@bentownsend1872
Жыл бұрын
UniFi Network and UniFi Protect are two different software packages, and Protect as far as I know does not have a self-host option. Unfortunately you won't be able to connect the camera to your instance that you've hosted yourself, you'll have to purchase a NVR in order to use the camera.
@matthiasnott
Жыл бұрын
@@bentownsend1872 That probably answers my question earlier. And what specifically is "Network" for then?
Anyone got this working behind a cloudflare tunnel? I’m struggling with adopting.
do you have a video on uisp controller,I'm having a lot of issues with installing it on debian 11
@LAWRENCESYSTEMS
5 ай бұрын
Nope, as I don't use that
never seem to get thos to work now it does not suport the arm chips but i have found a other way
Didn't work for me. Tried on a LXC Proxmox CT with an Ubuntu 20.04 template. The error was related to "unsafe" repositories.
@revd13
Жыл бұрын
This is the issue i'm having too. Scouring these comments for a solution...
@revd13
Жыл бұрын
Found the solution. right after making your container, add [trusted=yes] after the deb in your /etc/apt/sources.list for each entry. run apt-get update. then run apt-get upgrade. this will download all the missing crap the container doesnt have. the next step i did but i'm not sure is needed. i modified the script to add the same [trusted=yes] to the echo deb lines . ie. echo deb [trusted=yes]. after that everything worked as smoothly as the tutorial vid.
After updating I noticed that all devices said offline. Based on a discussion I saw, I turned off the firewall and all the devices showed up. What ports now require config in Windows firewall for controller and devices to work properly?
@LAWRENCESYSTEMS
Жыл бұрын
help.ui.com/hc/en-us/articles/218506997-UniFi-Network-Required-Ports-Reference
@DwayneKSmith876
Жыл бұрын
@@LAWRENCESYSTEMS Thank you
Yeah, I got it installed on 22.04, but the mongodb is a pain. I'd probably just use a vm for myself next time and go with 20.04 for now.
@ISBayHudson
Жыл бұрын
You can recompile against Jammy using the Bionic 3.6 official Mongo src deb
I don't waste resources on a VM, I always do a lxc or if in proxmox I will make a CT, much faster than a VM.
would love to combine Unifi controller and pfsense on 1 proxmox system. Maybe an idea for a video?
@markbifferos2765
7 ай бұрын
It's generally felt that pfsense should have its own hardware, but I'm one of the idiots trying this :). I don't have the right ethernet cards for pfSense and I'm too tight to dig in my pocket and get them. For my server I'm using Phenom X2 with 8GB RAM and an Intel 120GB SSD. Positively ancient hardware to be running my house on. Unifi: 2GB RAM, 1 CPU, 32GB disk, virtio network and disk. pfSense VM is exactly the same but I had to change the processor type because the default (with AES) won't work with the Phenom (used 'host' cpu for unifi, used 'phenom' for pfsense). It's a lot easier than unifi setup it either works (if you have the right hardware) or it doesn't!
@markbifferos2765
7 ай бұрын
PS: Yeah I know this uses way too much power, the fanless mini PC is on order.
I believe using ubuntu 22.04 with controller installed directly and mongodb in container should be the easiest solution for those problems. Has anyone tried it?
great video, trying to understand while trying to login to the unifi port 8443 I get this: Bad Request This combination of host and port requires TLS. I'm I missing something...
@maximusg88
Жыл бұрын
That's normal with unifi... Just click proceed
When I run the script on Ubuntu server 20.04 it says: line 1: payload:allShortcutsEnabled:false: command not found
@LAWRENCESYSTEMS
Жыл бұрын
Not an error that I have ever encountered.
@StenIsaksson
Жыл бұрын
@@LAWRENCESYSTEMS It worked when I manually copied the commands from the script.
Throwing the script and dockers under the bus bold move
@LAWRENCESYSTEMS
Жыл бұрын
Just trying to have people think more critically about supply chain attacks.
@Max-jv3yg
Жыл бұрын
@LawrenceSystems you can view the Docker image manifest and pin your pull version to a specific SHA. An interesting video idea would be to show how this (Docker) potential supply chain attack differs from say APT, PyPi, etc.
Does this work with an Unbuntu install on AWS?
@LAWRENCESYSTEMS
Жыл бұрын
Don't see why not.
where can I find the compact database option? Thanks
@LAWRENCESYSTEMS
Жыл бұрын
It is still in the classic UI at Settings > Maintenance > Services > Compact Database.
@badburn
Жыл бұрын
@@LAWRENCESYSTEMS I have to switch to Legacy UI first in order to access it then. I thought it is also available on the new UI.. thank you.
Some lifetime they will finally update Mongo to a non-ancient supported version...
what a fucking pain in the ass with ubiquiti!! latest update has jacked up all my ip addresses
Your script is not complete for Ubuntu 20.04.5 LTS. It complains about not having gnupg or gnupg2
@LAWRENCESYSTEMS
Жыл бұрын
It's their script that I copied.
@TheUKDude_
Жыл бұрын
@@LAWRENCESYSTEMS Yeah I know, I just thought I would let you know.
can a CISCO AP AIR-CAP2602l-E-KP9 work on this software
How i reboot it
I host mine on windows and it was fairly painless. On the windows side they now use openjdk rather than oracle which is nice.
God dammit.... I just rebuilt my system. FML. Literally in the last week.
This is not working for me. I'm trying to set this up for a simple G4 doorbell. Now I've the UniFi Protect app on my iPhone, and it just says "Set up a UniFi OS Console." Which doesn't make a lot of sense to me. I'm new to this ecosystem, obviously. I've installed the VM, followed your guideline, but this can logically not detect the device which has never been set up and is hence not on my network. The logical sequence should be to first configure that UniFi Protect to talk to the controller, and then use the Phone to use Bluetooth to pick up the device and register it with the controller. The controller is up and running. I did the configuration precisely like you did (except for adopting the device, obviously). How would the UniFi Protect app even know the controller? Will it portscan my whole network? The UniFi controller is on the same network as my Phone and it can ping the phone. There's a "Add Clients" section which looks like Computer/Tablet/Phone from its icon. I've added both my phone as well as the G4 Doorbell by their MAC address. Nothing shows up. This is highly confusing. I've the G2 coming today, which I'd actually rather not buy as I'm controlling only exactly one doorbell, and I've a whole bunch of VMs running on my Infrastructure. But it seems I just can't get this app on the phone talk to anything.
To this day I still refuse to use the new gui, his horrible. Seems to be a trend these days to make UI terrible across the board. Autotask just did the same, trashed what worked fine with a horrible ui with painful colouring
I assume no one is using this approach any longer as Ubuntu 20 reached EOL in April 2023? Getting Unifi controller 8 manually installed without using a script at this point is pretty painful, as Unifi controller v8.0 requierers mongodb 3.6 to 4.4, however Ubuntu 22 only allows for mongodb 6.0.4 and newer to be installed. So I'm still lost trying to figure out how to install the latest version of the unifi controller (8.0) onto the latest version of Ubuntu (22).
Can you make a video for windows from scratch installation, please?
@LAWRENCESYSTEMS
Жыл бұрын
Don't use Windows for UniFi
What about install on windows 10
Can you make a AWS lightsail version.
@LAWRENCESYSTEMS
Жыл бұрын
No, I don't use AWS Lightsail.
@ISBayHudson
Жыл бұрын
You'd also want to keep this off the Internet and accessible internally only. There are requirements for software which went end of life ~ 2020
funny i was just looking at this yesterday. went to install and found mongodb a requirement. threw up in my mouth, swallowed and said fine. clicked the link for ubuntu instructions which took me to a deprecated page on mongo’s site. said fuck that and installed the latest. the tried to install ubnt packages and it requires a mongo THREE MAJOR VERSIONS BEHIND LATEST. decided i’m fine using the bundled mac/win packages and went to dinner. tl;dr: ubnt doesnt like to do latest anything (see VPN options on their routers) and not worth installing on linux unless you need large scale or don’t use mac|win for daily driver
@80robina
Жыл бұрын
Like centos didn't have latest packages, I thought Ubuntu had more up to date packages ?
@enkaskal
Жыл бұрын
@@80robina tbh i didnt even notice or check. after installing their apt repo i tried to install the deb pkg and it complained about mongo which is what sent me down the rabbit hole 🤷♀️
@ISBayHudson
Жыл бұрын
Mongo DB changed their licensing in 2018 (?) which would require Ubiquiti to pay for the use of Mongo (ie. commercial use). I'd be very surprised if this isn't the reason they require the use of software which went end of lie 2020