DietPi-Software | UniFi Controller #5057
Replies: 76 comments 2 replies
-
I would to bring this topic up again. Here comes the Steps to Install Unifi on Dietpi. To add this to the Software Catalouge should be not a big deal: Install correct openJDK
Add Repo
Install Unifi |
Beta Was this translation helpful? Give feedback.
-
Hi, many thanks for your request. Just one comment from my side. I don't think it will be implemented if a dependency is |
Beta Was this translation helpful? Give feedback.
-
there is a work around for this. I am running the unifi controller on my dietpi raspberry pi 4, but it has to be done very early in the dietpi setup. I found the reference to this install script on the Ubiqui forums here: https://community.ui.com/questions/UniFi-Installation-Scripts-or-UniFi-Easy-Update-Script-or-UniFi-Lets-Encrypt-or-UniFi-Easy-Encrypt-/ccbc7530-dd61-40a7-82ec-22b17f027776
|
Beta Was this translation helpful? Give feedback.
-
@rhkean Thanks for sharing your Script. I would prefer to using the standard-way with Board-Instruments of Linux as desribed above. Then with this solution, an But I agree: without any additional customizings (like reducing the |
Beta Was this translation helpful? Give feedback.
-
well the script is still trying to install JAVA8. Not sure if this is an option for nonRPi systems |
Beta Was this translation helpful? Give feedback.
-
I would prefer that, too. Unfortunately, Ubiquiti's controller code
requires java 8 and there are several other packages that I ran into
problems with... This script worked, though.
To be clear, this is not my script. I found it on Ubiquiti's users forum.
…-rob
On Tue, Nov 17, 2020, 12:36 PM Gill Bates ***@***.***> wrote:
@rhkean <https://github.com/rhkean> Thanks for sharing your Script. I
would prefer to using the standard-way with Board-Instruments of Linux as
desribed above. Then with this solution, an apt dist-upgrade will also
auto-upgrade the Unifi-Controller - without additional Scripts.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#3708 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ADTEBBDKXKOKQ5DL643XF7TSQKYDFANCNFSM4PZJ7GOA>
.
|
Beta Was this translation helpful? Give feedback.
-
I'm not certain about what boards are supported, tbh.
You would have to read the scripts to find out. I do recall from my quick
glance a while back, that it does as much 'apt-get' as it can without
breaking anything.
…On Tue, Nov 17, 2020, 1:10 PM Joulinar ***@***.***> wrote:
well the script is still trying to install JAVA8. Not sure if this is an
option for nonRPi systems
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#3708 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ADTEBBGYC2WR4SF2G6LF3BLSQK4A5ANCNFSM4PZJ7GOA>
.
|
Beta Was this translation helpful? Give feedback.
-
I know. I just tried to highlight that the script will not change the requirement of JAVA8. And this limit the possible use case. Currently I'm trying to run the script on one of my VM's but it seems to be stuck somewhere during all the apt install steps 🤔 EDIT:
|
Beta Was this translation helpful? Give feedback.
-
Good find. That is somehow an issue as we already dropped several other software titles from Buster on, which depend on Java 8. Yes Raspbian contains it, but with upcoming Raspberry Pi OS 64-bit (and my in production testing Debian-based ARMv7 image), there will be mostly only RPi 1 and Zero left (+existing systems of course) which use Raspbian. And using binaries from old-old-stable (from summer on) repositories is not something I'm keen to do, although we did in other cases (e.g. libssl1.0.0). Would be interesting if there are any plans to make it Java 11 compatible? |
Beta Was this translation helpful? Give feedback.
-
Agreed.. for as popular as their devices are, I'm a bit dumbfounded that
they haven't brought it current, especially since they've brought other
dependencies current like mangodb.
…On Wed, Nov 18, 2020, 9:06 AM MichaIng ***@***.***> wrote:
Good find. That is somehow an issue as we already dropped several other
software titles from Buster on, which depend on Java 8. Yes Raspbian
contains it, but with upcoming Raspberry Pi OS 64-bit (and my in production
testing Debian-based ARMv7 image), there will be mostly only RPi 1 and Zero
left (+existing systems of course) which use Raspbian. And using binaries
from old-old-stable (from summer on) repositories is not something I'm keen
to do, although we did in other cases (e.g. libssl1.0.0).
Would be interesting if there are any plans to make it Java 11 compatible?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#3708 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ADTEBBEK7HZVNKUTAAHOS5TSQPIHBANCNFSM4PZJ7GOA>
.
|
Beta Was this translation helpful? Give feedback.
-
Or only applications that are compatible for the installed platform appear in the software catalog. :-) |
Beta Was this translation helpful? Give feedback.
-
Jep, that is how it is currently. However, to implement software for a very limited set of platforms is less of a pleasure of course, specially when it's about outdated dependencies which will break them on even the small left platforms earlier or later 😄. So for now it would be all Stretch platforms and Raspbian. Since it is famous for RPi which in combination which Raspbian still covers ~50% of our users, that should be worth enough to implement. |
Beta Was this translation helpful? Give feedback.
-
Does anyone know if the Unifi Controller has been resolved to work with the latest version of DietPi? Also, would it be possible to run PiHole and PiVPN/WireGuard on the same unit (RPi 3 B+) with the Controller or should I keep the controller separate? Thanks in advance! |
Beta Was this translation helpful? Give feedback.
-
Well if I'm not mistaken, issue was the requirement of JAVA8 which is quite old and outdated. |
Beta Was this translation helpful? Give feedback.
-
So if I install Openjdk8, I should be able to run all 3 on one device with DietPi? I'm a noob, so just trying to understand... |
Beta Was this translation helpful? Give feedback.
-
Should be possible according the 2 guides I posted above |
Beta Was this translation helpful? Give feedback.
-
OK, I really appreciate the assistance. I'll see if I can understand the guide. Thanks! |
Beta Was this translation helpful? Give feedback.
-
@MichaIng |
Beta Was this translation helpful? Give feedback.
-
As I edited into my post above, just note that you should compile it on an external drive (not an SD card!), have a large swap file in place (also not on an SD card), turn off all other services/software running on that RPi and let it running over night. At best attach an SSD via USB3 for swap file and building, so the disk I/O at least won't be a bottleneck. I not yet found a definit statement that MongoDB at its core does not support 32-bit, but rather that they stopped to ship 32-bit binaries. Else this would further complicate and limit the abilities to run Unifi Controller, as long as they do not support newer Java versions, as only Raspbian (32-bit) still ships Java 8 natively. Btw, did someone already try the MongoDB 64-bit ARM Ubuntu package (on our 64-bit image, of course)? https://repo.mongodb.org/apt/ubuntu/dists/focal/mongodb-org/5.0/multiverse/binary-arm64/mongodb-org-server_5.0.2_arm64.deb |
Beta Was this translation helpful? Give feedback.
-
@Fireman1224 Try it stupid simple. Don't mess around with compling if you don't have any clue about Linux. It will end up in wasting time and a lot of frustration (but you will learn a lot!) We were all Rookies once. :-)
|
Beta Was this translation helpful? Give feedback.
-
Ah nice, a Docker container exists. Not the implementation we'd add to |
Beta Was this translation helpful? Give feedback.
-
So I've never played around with docker, but from what little I have read, it seems like it will be easy enough to try. I had ended up just going back with Raspberry OS and then installing the Unifi Controller on that, but I need a second controller for another location that I have to configure, so I'm going to try the Docker approach. If I can make it work, I may re-do my current site with Docker instead. I appreciate the continued support and advice!! Question 1: If I set up the USB flash drive on a Pi 4, could I then use it in a Pi 3B+ or do I need to make some adjustments because of the RAM difference? Question 2: Will I have to run Question 3: How are the controller version updates handled within Docker? I apologize for the question bombardment, but this is a new area for me... Thanks! @ |
Beta Was this translation helpful? Give feedback.
-
A1: No adjustments required, but probably a swap file needs to be created or its size increased when the system on the RPi 4 used it, or used more than 1 GiB physical memory. A2: The Docker/containerd service itself starts all containers, after having them deployed once. A3: At least you need to remove the old container, before calling # Remove Docker container
docker rm "$(docker ps -a | mawk '/linuxserver\/unifi-controller/{print $1;exit}')"
# Remove Docker image
docker rmi "$(docker images -a | mawk '/linuxserver\/unifi-controller/{print $3;exit}')" |
Beta Was this translation helpful? Give feedback.
-
usually the image can be removed as well as a new version will be download. Depending on the Docker application you would need to check if personal data are stored on a location outside the container to ensure not starting from scratch. |
Beta Was this translation helpful? Give feedback.
-
If settings/data are stored within the Docker image, is removing the container actually sufficient to have it updated, or does this only remove the "image" from being started/controlled by the parent Docker service? |
Beta Was this translation helpful? Give feedback.
-
Removing the container will have no impact on the image as it will not be updated. Creating a new container will reuse the old image again. That's why The image provider ( https://hub.docker.com/r/linuxserver/unifi-controller
|
Beta Was this translation helpful? Give feedback.
-
Thanks for clarification. So then the two commands I provided above should do the job, followed by |
Beta Was this translation helpful? Give feedback.
-
Running the Docker Container will work on a Rpi 3+, but it’s no joy! i miss the days, where a simple |
Beta Was this translation helpful? Give feedback.
-
Basically JAVA8 should not be the issue as you could install it from AdoptOpenJDK repository https://adoptopenjdk.net/installation.html?variant=openjdk8&jvmVariant=hotspot#linux-pkg It's still MongoDB not being available that simple on ARM boards. Therefore, using Docker container seems to be the easiest solution currently. Regarding memory consumption, I guess it would be similar without docker. At least on my test, nearly 600MB are used by JAVA 😉 Below a view from my Docker installation for Unifi. BTW: version running inside the container
|
Beta Was this translation helpful? Give feedback.
-
And this still works with the ARMv6 image. @Joulinar But no APT repository exists yet, so install needs to be done manually: curl -sSfLO https://github.com/adoptium/temurin8-binaries/releases/download/jdk8u-2021-09-02-03-07-beta/OpenJDK8U-jre_arm_linux_hotspot_2021-09-02-03-07.tar.gz
tar xf OpenJDK8U-jre_arm_linux_hotspot_2021-09-02-03-07.tar.gz -C /opt
ln -s /opt/jdk8u312-b03-jre/bin/java /usr/local/bin/java |
Beta Was this translation helpful? Give feedback.
-
The Unifi Controller is a very popular tool on the Raspberry. I found a guide on the net how to install it:
https://smarthome-training.com/de/unifi-controller-raspberry-pi/
Does anyone have the time and inclination to add the Unifi controller to the software archive so that it can be easily installed via
dietpi-software
?PS: Be aware of the missing JAVA_HOME-Bug: https://community.ui.com/questions/Java-Home-Directory-Fail-Issue-on-Ubuntu-RESOLVED/1faea5fd-6eda-4be9-a12f-676ef6be2529
ADMIN EDIT: Please use the up arrow at this post to vote for integrating this software title.
Beta Was this translation helpful? Give feedback.
All reactions