Closed jeroenhe closed 3 years ago
I have the same issue !
output :
unifi-video-controller | 2021-03-16 11:56:56.796182 Waiting for mongodb to come online...Java VM created successfully unifi-video-controller | Class org/apache/commons/daemon/support/DaemonLoader found unifi-video-controller | Native methods registered unifi-video-controller | java_init done unifi-video-controller | Daemon loading... unifi-video-controller | java.lang.ClassFormatError: Illegal method name "new.super" in class com/ubnt/airvision/Main unifi-video-controller | at java.lang.ClassLoader.defineClass1(Native Method) unifi-video-controller | at java.lang.ClassLoader.defineClass(ClassLoader.java:756) unifi-video-controller | at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142) unifi-video-controller | at java.net.URLClassLoader.defineClass(URLClassLoader.java:468) unifi-video-controller | at java.net.URLClassLoader.access$100(URLClassLoader.java:74) unifi-video-controller | at java.net.URLClassLoader$1.run(URLClassLoader.java:369) unifi-video-controller | at java.net.URLClassLoader$1.run(URLClassLoader.java:363) unifi-video-controller | at java.security.AccessController.doPrivileged(Native Method) unifi-video-controller | at java.net.URLClassLoader.findClass(URLClassLoader.java:362) unifi-video-controller | at java.lang.ClassLoader.loadClass(ClassLoader.java:418) unifi-video-controller | at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:352) unifi-video-controller | at java.lang.ClassLoader.loadClass(ClassLoader.java:351) unifi-video-controller | at org.apache.commons.daemon.support.DaemonLoader.load(DaemonLoader.java:151) unifi-video-controller | Cannot load daemon unifi-video-controller | java_load failed unifi-video-controller | Service exit with a return value of 3
docker info :
Client:
Debug Mode: false
Server:
Containers: 2
Running: 0
Paused: 0
Stopped: 2
Images: 16
Server Version: 19.03.15
Storage Driver: overlay2
Backing Filesystem: extfs
Supports d_type: true
Native Overlay Diff: true
Logging Driver: json-file
Cgroup Driver: cgroupfs
Plugins:
Volume: local
Network: bridge host ipvlan macvlan null overlay
Log: awslogs fluentd gcplogs gelf journald json-file local logentries splunk syslog
Swarm: inactive
Runtimes: runc
Default Runtime: runc
Init Binary: docker-init
containerd version: ea765aba0d05254012b0b9e595e995c09186427f
runc version: dc9208a3303feef5b3839f4323d9beb36df0a9dd
init version: fec3683
Security Options:
seccomp
Profile: default
Kernel Version: 4.14.138-rancher
Operating System: RancherOS v1.5.8
OSType: linux
Architecture: x86_64
CPUs: 2
Total Memory: 2.949GiB
Name: rancheros.domain.me
ID: YM67:YQWD:62KO:Z2HT:TDCS:UBNX:DZQL:UHCD:7PHK:GRJO:VKNU:DMP7
Docker Root Dir: /var/lib/docker
Debug Mode: false
Registry: https://index.docker.io/v1/
Labels:
Experimental: false
Insecure Registries:
127.0.0.0/8
Live Restore Enabled: false
Product License: Community Engine
docker-compose.yaml
version: '2'
services:
unifi-video:
image: "pducharme/unifi-video-controller"
build: .
container_name: unifi-video-controller
cap_add:
- DAC_READ_SEARCH
ports:
- 10001:10001
- 1935:1935
- 6666:6666
- 7080:7080
- 7442:7442
- 7443:7443
- 7444:7444
- 7445:7445
- 7446:7446
- 7447:7447
environment:
- TZ=Europe/Brussels
- PUID=<<UID>>
- PGID=<<GID>>
- CREATE_TMPFS=no
- DEBUG=1
volumes:
- nfsUdata:/var/lib/unifi-video:nocopy
- nfsUvideo:/var/lib/unifi-video/videos
- cacheUvideo:/var/cache/unifi-video
restart: always
# privileged: true
volumes:
nfsUdata:
#driver: nfs
driver_opts:
type: "nfs"
o: "addr=<<IP>>,nolock,soft,rw"
device: ":/volume/unifi-video/data/"
nfsUvideo:
#driver: nfs
driver_opts:
type: "nfs"
o: "addr=<<IP>>,nolock,soft,rw"
device: ":/volume/unifi-video/video/"
cacheUvideo:
driver_opts:
type: tmpfs
device: tmpfs
Tya for the support :-)
* different openjdk java version? Yes: `1.8.0_265` vs `1.8.0_282`
I believe this is your issue, I restarted a non-docker version of unifi-video-controller yesterday and a java update broke the controller, I manually installed the old version and it worked fine after that.
* different openjdk java version? Yes: `1.8.0_265` vs `1.8.0_282`
I believe this is your issue, I restarted a non-docker version of unifi-video-controller yesterday and a java update broke the controller, I manually installed the old version and it worked fine after that.
Thank you for mentioning that. I'll have a try at fixing the specific version and report results back here.
I've "downgraded" java to the specific version/release openjdk-8-jre-headless=8u162-b12-1
and now unifi-video boots again. There is one exception left, but it doesn't seem to matter much:
Exception in thread "EmsInitTask" java.lang.NullPointerException
at com.ubnt.airvision.service.ems.C.void.new(Unknown Source)
at com.ubnt.airvision.service.ems.C$1.run(Unknown Source)
at java.lang.Thread.run(Thread.java:748)
So, the Dockerfile that now produces a working unifi-video server contains openjdk-8-jre-headless=8u162-b12-1 \
on line 29 instead of openjdk-8-jre-headless
.
If anyone finds nice way to install the 1.8.0_265
version using apt, let me know. This issue is now fixed for me, so I'm closing it. In my opinion it's not worthy of a PR, unless we can find a nice way of installing the "correct" required Java version in a decent way.
@jeroenhendricksen not exactly what you're after but I was able to revert the ubuntu xenial security update the broke my unifi video by first finding out the available versions:
# apt-cache policy openjdk-8-jre-headless
openjdk-8-jre-headless:
Installed: 8u292-b10-0ubuntu1~16.04.1
Candidate: 8u292-b10-0ubuntu1~16.04.1
Version table:
*** 8u292-b10-0ubuntu1~16.04.1 500
500 http://au.archive.ubuntu.com/ubuntu xenial-updates/main amd64 Packages
500 http://security.ubuntu.com/ubuntu xenial-security/main amd64 Packages
100 /var/lib/dpkg/status
8u77-b03-3ubuntu3 500
500 http://au.archive.ubuntu.com/ubuntu xenial/main amd64 Packages
And then installing the older version:
# apt-get install openjdk-8-jre-headless:amd64=8u77-b03-3ubuntu3
I have an issue with the unifi video controller where it won't start properly, specifically with a custom built image. Before anyone wonders why I would build my own custom image anyway when there is a working one, I did that to add customisations that allow me to install a custom webserver certificate. What is weird is that the image that was built 5 months ago works properly (
pducharme/unifi-video-controller
), but when I build it myself (based on presumably the exact same Dockerfile) it doesn't work properly. I suspect this is caused by something that has changed with the dependencies that are installed into the image via apt, because that's the only thing that is different for as far as I know.Reproducing the issue
In a clean setup, this works:
But this does not (build the image yourself):
My questions
phusion/baseimage:0.11
: seems not, was Last pushed3 years ago1.8.0_265
vs1.8.0_282
v4.0.19
vsv4.0.23