You are not logged in.

#1 2018-10-04 14:32:51

K3N8
Member
From: The Netherlands
Registered: 2011-11-02
Posts: 62

[Solved] Unifi controller

Hi,

I have had a lot of issues with the Unifi controller from AUR. I tried to install it, but it crashes all the time. Does anybody know a way to get installed? It would be a shame to ditch Arch Linux just for this very important package.

Thanks,

Alexander

Last edited by K3N8 (2018-10-05 09:14:09)


Arch Linux x86_64 LTS

Offline

#2 2018-10-04 14:56:14

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 21,743

Re: [Solved] Unifi controller

Offline

#3 2018-10-04 15:58:20

K3N8
Member
From: The Netherlands
Registered: 2011-11-02
Posts: 62

Re: [Solved] Unifi controller

● unifi.service - Ubiquiti UniFi Server
   Loaded: loaded (/usr/lib/systemd/system/unifi.service; disabled; vendor preset: disabled)
   Active: failed (Result: exit-code) since Thu 2018-10-04 17:44:50 CEST; 11s ago
  Process: 6510 ExecStart=/usr/bin/java -jar /usr/lib/unifi/lib/ace.jar start (code=exited, status=1/FAILURE)
 Main PID: 6510 (code=exited, status=1/FAILURE)

okt 04 17:44:50 arch java[6510]:         at java.base/java.lang.reflect.Method.invoke(Method.java:564)
okt 04 17:44:50 arch java[6510]:         at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:160)
okt 04 17:44:50 arch java[6510]:         ... 60 more
okt 04 17:44:50 arch java[6510]: Caused by: java.lang.ClassNotFoundException: javax.activation.DataSource
okt 04 17:44:50 arch java[6510]:         at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:582)
okt 04 17:44:50 arch java[6510]:         at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:190)
okt 04 17:44:50 arch java[6510]:         at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:499)
okt 04 17:44:50 arch java[6510]:         ... 71 more
okt 04 17:44:50 arch systemd[1]: unifi.service: Main process exited, code=exited, status=1/FAILURE
okt 04 17:44:50 arch systemd[1]: unifi.service: Failed with result 'exit-code'.

Arch Linux x86_64 LTS

Offline

#4 2018-10-04 17:08:45

loqs
Member
Registered: 2014-03-06
Posts: 17,378

Re: [Solved] Unifi controller

What is the output of `/usr/bin/java -version`

Offline

#5 2018-10-04 21:10:21

K3N8
Member
From: The Netherlands
Registered: 2011-11-02
Posts: 62

Re: [Solved] Unifi controller

openjdk 10.0.2 2018-07-17
OpenJDK Runtime Environment (build 10.0.2+13)
OpenJDK 64-Bit Server VM (build 10.0.2+13, mixed mode)

Arch Linux x86_64 LTS

Offline

#6 2018-10-04 21:41:47

loqs
Member
Registered: 2014-03-06
Posts: 17,378

Re: [Solved] Unifi controller

unifi needs java-runtime-headless<9 and java-runtime-headless>=8 which means it needs java-runtime-headless=8

Offline

#7 2018-10-04 21:45:11

progandy
Member
Registered: 2012-05-17
Posts: 5,199

Re: [Solved] Unifi controller

https://wiki.archlinux.org/index.php/Ja … va_version

I think unifi needs java 8, so the service file should probably be changed like this:

Environment="PATH=/usr/lib/jvm/java-8-openjdk/jre/bin:/usr/local/bin:/usr/bin"
ExecStart=/usr/lib/jvm/java-8-openjdk/jre/bin/java -jar /usr/lib/unifi/lib/ace.jar start
ExecStop=/usr/lib/jvm/java-8-openjdk/jre/bin/java -jar /usr/lib/unifi/lib/ace.jar stop

There is also the docker image as a last alternative.

Last edited by progandy (2018-10-04 21:49:06)


| alias CUTF='LANG=en_XX.UTF-8@POSIX ' |

Offline

#8 2018-10-05 09:13:54

K3N8
Member
From: The Netherlands
Registered: 2011-11-02
Posts: 62

Re: [Solved] Unifi controller

Hi guys,

Thank you very much, this was very helpful! The problem was the Java version. I just installed the default version. After I installed Java 8. It worked perfectly.

Regards,

Alexander

Last edited by K3N8 (2018-10-05 09:14:24)


Arch Linux x86_64 LTS

Offline

Board footer

Powered by FluxBB