linuxserver / docker-unifi-network-application

GNU General Public License v3.0
553 stars 41 forks source link

[BUG] After Backup Import, the Dashboard is offline #40

Closed iMonZ closed 7 months ago

iMonZ commented 7 months ago

Is there an existing issue for this?

Current Behavior

Unifi page shows after importing the config a 404

Expected Behavior

No response

Steps To Reproduce

  1. Importing the Dashboard file

Environment

- OS: macOS
- How docker service was installed: over Homebrew and then updated over the Interface

CPU architecture

arm64

Docker creation

Using the Docker Compose file

Container logs

2023-11-23 11:24:30 [migrations] started
2023-11-23 11:24:30 [migrations] no migrations found
2023-11-23 11:24:31 ───────────────────────────────────────
2023-11-23 11:24:31 
2023-11-23 11:24:31       ██╗     ███████╗██╗ ██████╗ 
2023-11-23 11:24:31       ██║     ██╔════╝██║██╔═══██╗
2023-11-23 11:24:31       ██║     ███████╗██║██║   ██║
2023-11-23 11:24:31       ██║     ╚════██║██║██║   ██║
2023-11-23 11:24:31       ███████╗███████║██║╚██████╔╝
2023-11-23 11:24:31       ╚══════╝╚══════╝╚═╝ ╚═════╝ 
2023-11-23 11:24:31 
2023-11-23 11:24:31    Brought to you by linuxserver.io
2023-11-23 11:24:31 ───────────────────────────────────────
2023-11-23 11:24:31 
2023-11-23 11:24:31 To support LSIO projects visit:
2023-11-23 11:24:31 https://www.linuxserver.io/donate/
2023-11-23 11:24:31 
2023-11-23 11:24:31 ───────────────────────────────────────
2023-11-23 11:24:31 GID/UID
2023-11-23 11:24:31 ───────────────────────────────────────
2023-11-23 11:24:31 
2023-11-23 11:24:31 User UID:    1000
2023-11-23 11:24:31 User GID:    1000
2023-11-23 11:24:31 ───────────────────────────────────────
2023-11-23 11:24:31 
2023-11-23 11:24:31 *** Waiting for MONGO_HOST unifi-mongo to be reachable. ***
2023-11-23 11:24:35 Generating 4,096 bit RSA key pair and self-signed certificate (SHA384withRSA) with a validity of 3,650 days
2023-11-23 11:24:35     for: CN=unifi
2023-11-23 11:24:35 [custom-init] No custom files found, skipping...
2023-11-23 11:24:51 [ls.io-init] done.
2023-11-23 11:37:56 org.tuckey.web.filters.urlrewrite.UrlRewriteFilter INFO: destroy called
2023-11-23 11:38:04 [migrations] started
2023-11-23 11:38:04 [migrations] no migrations found
2023-11-23 11:38:04 usermod: no changes
2023-11-23 11:38:04 ───────────────────────────────────────
2023-11-23 11:38:04 
2023-11-23 11:38:04       ██╗     ███████╗██╗ ██████╗ 
2023-11-23 11:38:04       ██║     ██╔════╝██║██╔═══██╗
2023-11-23 11:38:04       ██║     ███████╗██║██║   ██║
2023-11-23 11:38:04       ██║     ╚════██║██║██║   ██║
2023-11-23 11:38:04       ███████╗███████║██║╚██████╔╝
2023-11-23 11:38:04       ╚══════╝╚══════╝╚═╝ ╚═════╝ 
2023-11-23 11:38:04 
2023-11-23 11:38:04    Brought to you by linuxserver.io
2023-11-23 11:38:04 ───────────────────────────────────────
2023-11-23 11:38:04 
2023-11-23 11:38:04 To support LSIO projects visit:
2023-11-23 11:38:04 https://www.linuxserver.io/donate/
2023-11-23 11:38:04 
2023-11-23 11:38:04 ───────────────────────────────────────
2023-11-23 11:38:04 GID/UID
2023-11-23 11:38:04 ───────────────────────────────────────
2023-11-23 11:38:04 
2023-11-23 11:38:04 User UID:    1000
2023-11-23 11:38:04 User GID:    1000
2023-11-23 11:38:04 ───────────────────────────────────────
2023-11-23 11:38:04 
2023-11-23 11:38:04 [custom-init] No custom files found, skipping...
2023-11-23 11:38:17 [ls.io-init] done.
2023-11-23 11:47:18 org.tuckey.web.filters.urlrewrite.UrlRewriteFilter INFO: destroy called
2023-11-23 11:48:12 :1023 Permanent error code on channel bind request: 400 - Empty port number in channel bind request
2023-11-23 11:48:12 :1023 Permanent error code on channel bind request: 403 - Forbidden IP
2023-11-23 11:48:12 :484 All TURN channel bindings failed
2023-11-23 11:48:12 #
2023-11-23 11:48:12 # A fatal error has been detected by the Java Runtime Environment:
2023-11-23 11:48:12 #
2023-11-23 11:48:12 #  SIGSEGV (0xb) at pc=0x0020fffec314328c, pid=402, tid=561
2023-11-23 11:48:12 #
2023-11-23 11:48:12 # JRE version: OpenJDK Runtime Environment (17.0.8.1+1) (build 17.0.8.1+1-Ubuntu-0ubuntu122.04)
2023-11-23 11:48:12 # Java VM: OpenJDK 64-Bit Server VM (17.0.8.1+1-Ubuntu-0ubuntu122.04, mixed mode, sharing, tiered, compressed oops, compressed class ptrs, parallel gc, linux-aarch64)
2023-11-23 11:48:12 # Problematic frame:
2023-11-23 11:48:12 # C  0x0020fffec3143288
2023-11-23 11:48:12 #
2023-11-23 11:48:12 # No core dump will be written. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again
2023-11-23 11:48:12 #
2023-11-23 11:48:12 # An error report file with more information is saved as:
2023-11-23 11:48:12 # /config/hs_err_pid402.log
2023-11-23 11:48:12 #
2023-11-23 11:48:12 # If you would like to submit a bug report, please visit:
2023-11-23 11:48:12 #   Unknown
2023-11-23 11:48:12 # The crash happened outside the Java Virtual Machine in native code.
2023-11-23 11:48:12 # See problematic frame for where to report the bug.
2023-11-23 11:48:12 #
2023-11-23 11:48:32 :1023 Permanent error code on channel bind request: 400 - Empty port number in channel bind request
2023-11-23 11:48:32 :1023 Permanent error code on channel bind request: 403 - Forbidden IP
2023-11-23 11:48:33 :484 All TURN channel bindings failed
2023-11-23 11:48:33 #
2023-11-23 11:48:33 # A fatal error has been detected by the Java Runtime Environment:
2023-11-23 11:48:33 #
2023-11-23 11:48:33 #  SIGSEGV (0xb) at pc=0x0020fffec734328c, pid=665, tid=793
2023-11-23 11:48:33 #
2023-11-23 11:48:33 # JRE version: OpenJDK Runtime Environment (17.0.8.1+1) (build 17.0.8.1+1-Ubuntu-0ubuntu122.04)
2023-11-23 11:48:33 # Java VM: OpenJDK 64-Bit Server VM (17.0.8.1+1-Ubuntu-0ubuntu122.04, mixed mode, sharing, tiered, compressed oops, compressed class ptrs, parallel gc, linux-aarch64)
2023-11-23 11:48:33 # Problematic frame:
2023-11-23 11:48:33 # C  0x0020fffec7343288
2023-11-23 11:48:33 #
2023-11-23 11:47:19 Exception in thread "Thread-8" java.lang.IllegalStateException: BeanFactory not initialized or already closed - call 'refresh' before accessing beans via the ApplicationContext
2023-11-23 11:47:19     at org.springframework.context.support.AbstractRefreshableApplicationContext.getBeanFactory(AbstractRefreshableApplicationContext.java:168)
2023-11-23 11:47:19     at org.springframework.context.support.AbstractApplicationContext.getBean(AbstractApplicationContext.java:1172)
2023-11-23 11:47:19     at com.ubnt.service.ooOO.Ö00000(Unknown Source)
2023-11-23 11:47:19     at com.ubnt.ace.Launcher.Ö00000(Unknown Source)
2023-11-23 11:47:19     at java.base/java.lang.Thread.run(Thread.java:833)
2023-11-23 11:48:33 # No core dump will be written. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again
2023-11-23 11:48:33 #
2023-11-23 11:48:33 # An error report file with more information is saved as:
2023-11-23 11:48:33 # /config/hs_err_pid665.log
2023-11-23 11:48:33 [thread 731 also had an error]
2023-11-23 11:48:33 [thread 866 also had an error]
2023-11-23 11:48:33 #
2023-11-23 11:48:33 # If you would like to submit a bug report, please visit:
2023-11-23 11:48:33 #   Unknown
2023-11-23 11:48:33 # The crash happened outside the Java Virtual Machine in native code.
2023-11-23 11:48:33 # See problematic frame for where to report the bug.
2023-11-23 11:48:33 #
2023-11-23 11:48:50 :1023 Permanent error code on channel bind request: 403 - Forbidden IP
2023-11-23 11:48:50 :1023 Permanent error code on channel bind request: 400 - Empty port number in channel bind request
2023-11-23 11:48:50 :484 All TURN channel bindings failed
2023-11-23 11:48:50 #
2023-11-23 11:48:50 # A fatal error has been detected by the Java Runtime Environment:
2023-11-23 11:48:50 #
2023-11-23 11:48:50 #  SIGSEGV (0xb) at pc=0x0020fffee234328c, pid=871, tid=1004
2023-11-23 11:48:50 #
2023-11-23 11:48:50 # JRE version: OpenJDK Runtime Environment (17.0.8.1+1) (build 17.0.8.1+1-Ubuntu-0ubuntu122.04)
2023-11-23 11:48:50 # Java VM: OpenJDK 64-Bit Server VM (17.0.8.1+1-Ubuntu-0ubuntu122.04, mixed mode, sharing, tiered, compressed oops, compressed class ptrs, parallel gc, linux-aarch64)
2023-11-23 11:48:50 # Problematic frame:
2023-11-23 11:48:50 # C  0x0020fffee2343288
2023-11-23 11:48:50 #
2023-11-23 11:48:50 # No core dump will be written. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again
2023-11-23 11:48:50 #
2023-11-23 11:48:50 # An error report file with more information is saved as:
2023-11-23 11:48:50 # /config/hs_err_pid871.log
2023-11-23 11:48:50 #
2023-11-23 11:48:50 # If you would like to submit a bug report, please visit:
2023-11-23 11:48:50 #   Unknown
2023-11-23 11:48:50 # The crash happened outside the Java Virtual Machine in native code.
2023-11-23 11:48:50 # See problematic frame for where to report the bug.
2023-11-23 11:48:50 #
2023-11-23 11:49:09 :1023 Permanent error code on channel bind request: 403 - Forbidden IP
2023-11-23 11:49:09 :1023 Permanent error code on channel bind request: 400 - Empty port number in channel bind request
2023-11-23 11:49:09 :484 All TURN channel bindings failed
2023-11-23 11:49:09 #
2023-11-23 11:49:09 # A fatal error has been detected by the Java Runtime Environment:
2023-11-23 11:49:09 #
2023-11-23 11:49:09 #  SIGSEGV (0xb) at pc=0x0020fffee614328c, pid=1070, tid=1196
2023-11-23 11:49:09 #
2023-11-23 11:49:09 # JRE version: OpenJDK Runtime Environment (17.0.8.1+1) (build 17.0.8.1+1-Ubuntu-0ubuntu122.04)
2023-11-23 11:49:09 # Java VM: OpenJDK 64-Bit Server VM (17.0.8.1+1-Ubuntu-0ubuntu122.04, mixed mode, sharing, tiered, compressed oops, compressed class ptrs, parallel gc, linux-aarch64)
2023-11-23 11:49:09 # Problematic frame:
2023-11-23 11:49:09 # C  0x0020fffee6143288
2023-11-23 11:49:09 #
2023-11-23 11:49:09 # No core dump will be written. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again
2023-11-23 11:49:09 #
2023-11-23 11:49:09 # An error report file with more information is saved as:
2023-11-23 11:49:09 # /config/hs_err_pid1070.log
2023-11-23 11:49:09 #
2023-11-23 11:49:09 # If you would like to submit a bug report, please visit:
2023-11-23 11:49:09 #   Unknown
2023-11-23 11:49:09 # The crash happened outside the Java Virtual Machine in native code.
2023-11-23 11:49:09 # See problematic frame for where to report the bug.
2023-11-23 11:49:09 #
2023-11-23 11:49:27 :1023 Permanent error code on channel bind request: 400 - Empty port number in channel bind request
2023-11-23 11:49:27 :1023 Permanent error code on channel bind request: 403 - Forbidden IP
2023-11-23 11:49:28 :484 All TURN channel bindings failed
2023-11-23 11:49:28 #
2023-11-23 11:49:28 # A fatal error has been detected by the Java Runtime Environment:
2023-11-23 11:49:28 #
2023-11-23 11:49:28 #  SIGSEGV (0xb) at pc=0x0020ffff0514328c, pid=1263, tid=1393
2023-11-23 11:49:28 #
2023-11-23 11:49:28 # JRE version: OpenJDK Runtime Environment (17.0.8.1+1) (build 17.0.8.1+1-Ubuntu-0ubuntu122.04)
2023-11-23 11:49:28 # Java VM: OpenJDK 64-Bit Server VM (17.0.8.1+1-Ubuntu-0ubuntu122.04, mixed mode, sharing, tiered, compressed oops, compressed class ptrs, parallel gc, linux-aarch64)
2023-11-23 11:49:28 # Problematic frame:
2023-11-23 11:49:28 # C  0x0020ffff05143288
2023-11-23 11:49:28 #
2023-11-23 11:49:28 # No core dump will be written. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again
2023-11-23 11:49:28 #
2023-11-23 11:49:28 # An error report file with more information is saved as:
2023-11-23 11:49:28 # /config/hs_err_pid1263.log
2023-11-23 11:49:28 :1023 Permanent error code on channel bind request: 400 - Empty port number in channel bind request
2023-11-23 11:49:28 :1023 Permanent error code on channel bind request: 403 - Forbidden IP
2023-11-23 11:49:28 :484 All TURN channel bindings failed
2023-11-23 11:49:28 [thread 1394 also had an error]
2023-11-23 11:49:28 #
2023-11-23 11:49:28 # If you would like to submit a bug report, please visit:
2023-11-23 11:49:28 #   Unknown
2023-11-23 11:49:28 # The crash happened outside the Java Virtual Machine in native code.
2023-11-23 11:49:28 # See problematic frame for where to report the bug.
2023-11-23 11:49:28 #
2023-11-23 11:49:45 :1023 Permanent error code on channel bind request: 400 - Empty port number in channel bind request
2023-11-23 11:49:45 :1023 Permanent error code on channel bind request: 403 - Forbidden IP
2023-11-23 11:49:45 :484 All TURN channel bindings failed
2023-11-23 11:49:45 #
2023-11-23 11:49:45 # A fatal error has been detected by the Java Runtime Environment:
2023-11-23 11:49:45 #
2023-11-23 11:49:45 #  SIGSEGV (0xb) at pc=0x0020fffed774328c, pid=1455, tid=1585
2023-11-23 11:49:45 #
2023-11-23 11:49:45 # JRE version: OpenJDK Runtime Environment (17.0.8.1+1) (build 17.0.8.1+1-Ubuntu-0ubuntu122.04)
2023-11-23 11:49:45 # Java VM: OpenJDK 64-Bit Server VM (17.0.8.1+1-Ubuntu-0ubuntu122.04, mixed mode, sharing, tiered, compressed oops, compressed class ptrs, parallel gc, linux-aarch64)
2023-11-23 11:49:45 # Problematic frame:
2023-11-23 11:49:45 # C  0x0020fffed7743288
2023-11-23 11:49:45 #
2023-11-23 11:49:45 # No core dump will be written. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again
2023-11-23 11:49:45 #
2023-11-23 11:49:45 # An error report file with more information is saved as:
2023-11-23 11:49:45 # /config/hs_err_pid1455.log
2023-11-23 11:49:45 #
2023-11-23 11:49:45 # If you would like to submit a bug report, please visit:
2023-11-23 11:49:45 #   Unknown
2023-11-23 11:49:45 # The crash happened outside the Java Virtual Machine in native code.
2023-11-23 11:49:45 # See problematic frame for where to report the bug.
2023-11-23 11:49:45 #
j0nnymoe commented 7 months ago

Likely due to the backup having specific settings for a Macos installed as it's having issues binding to IP's that aren't there.

iMonZ commented 7 months ago

Likely due to the backup having specific settings for a Macos installed as it's having issues binding to IP's that aren't there.

Thanks! Solved the issue with using OrbStack instead of Docker. Works now!

iMonZ commented 7 months ago

Likely due to the backup having specific settings for a Macos installed as it's having issues binding to IP's that aren't there.

Just a small question. Ony my Unifi AP Device it stuck at adopting and set-inform command doesnt exist. Do you know how I can fix that?

iMonZ commented 7 months ago

Likely due to the backup having specific settings for a Macos installed as it's having issues binding to IP's that aren't there.

Just a small question. Ony my Unifi AP Device it stuck at adopting and set-inform command doesnt exist. Do you know how I can fix that?

U6-Enterprise-BZ.6.6.54# set-inform /bin/ash: set-inform: not found

j0nnymoe commented 7 months ago

You need to set the inform URL within the controler. No idea why your device doesn't have set-inform. You'll need to check unifi documentation.

j0nnymoe commented 7 months ago

Also note, we don't test/support orbstack, so any issues, we're unable to troubleshoot with that.

iMonZ commented 7 months ago

These are my logs

:1023 Permanent error code on channel bind request: 400 - Empty port number in channel bind request :1023 Permanent error code on channel bind request: 403 - Forbidden IP :484 All TURN channel bindings failed :948 Unable to read data from SCTP socket. Permanent error: (104) Connection reset by peer :366 SCTP ingest failed :220 SCTP ingest failed :221 Unable to do SSL I/O :906 webRtcId 1 terminated with code: (-2147090409) WebRTC connection interrupted from far side :1023 Permanent error code on channel bind request: 403 - Forbidden IP :1023 Permanent error code on channel bind request: 400 - Empty port number in channel bind request :1023 Permanent error code on channel bind request: 400 - Empty port number in channel bind request :484 All TURN channel bindings failed :948 Unable to read data from SCTP socket. Permanent error: (104) Connection reset by peer :366 SCTP ingest failed :220 SCTP ingest failed :221 Unable to do SSL I/O :906 webRtcId 3 terminated with code: (-2147090409) WebRTC connection interrupted from far side :585 STUN id: 4; fd: 195 192.168.228.3:39267 -> 213.55.243.56:26400 (eth0) DTLS id: 0 () (PEER) timed out :585 STUN id: 5; fd: 195 192.168.228.3:39267 -> 18.156.18.159:18577 (eth0) DTLS id: 0 () (PEER) timed out :585 STUN id: 6; fd: 195 192.168.228.3:39267 -> 192.168.1.9:62097 (eth0) DTLS id: 0 () (PEER) timed out

iMonZ commented 7 months ago

Also note, we don't test/support orbstack, so any issues, we're unable to troubleshoot with that.

This is my engine config:

{ "experimental" : true, "ipv6" : true }

Is this fine or should I remove something from here?

j0nnymoe commented 7 months ago

I have no idea, like I said, we don't test in that platform. https://docs.linuxserver.io/misc/support-policy/

iMonZ commented 7 months ago

I have no idea, like I said, we don't test in that platform. https://docs.linuxserver.io/misc/support-policy/

Okay thanks I switched now to docker desktop and get the exact same error. I have the latest docker desktop version.

iMonZ commented 7 months ago

@j0nnymoe Thats my docker compose file:

version: "2.1"
services:
  unifi-network-application:
    image: lscr.io/linuxserver/unifi-network-application:latest
    container_name: unifi-network-application
    environment:
      - PUID=1000
      - PGID=1000
      - TZ=Europe/Zurich
      - MONGO_USER=MONGO_USER
      - MONGO_PASS=MONGO_PASS
      - MONGO_HOST=unifi-mongo
      - MONGO_PORT=27017
      - MONGO_DBNAME=MONGO_DBNAME
      - MEM_LIMIT=1024 #optional
      - MEM_STARTUP=1024 #optional
      - MONGO_TLS= #optional
      - MONGO_AUTHSOURCE= #optional
    volumes:
      - ../Docker-Files:/config
    ports:
      - 8443:8443
      - 3478:3478/udp
      - 10001:10001/udp
      - 8080:8080
      - 1900:1900/udp #optional
      - 8843:8843 #optional
      - 8880:8880 #optional
      - 6789:6789 #optional
      - 5514:5514/udp #optional
    restart: always
    networks:
      - unifi-network
networks:
  unifi-network:
    external: true
iMonZ commented 7 months ago

@j0nnymoe Thats my docker compose file:

version: "2.1"
services:
  unifi-network-application:
    image: lscr.io/linuxserver/unifi-network-application:latest
    container_name: unifi-network-application
    environment:
      - PUID=1000
      - PGID=1000
      - TZ=Europe/Zurich
      - MONGO_USER=MONGO_USER
      - MONGO_PASS=MONGO_PASS
      - MONGO_HOST=unifi-mongo
      - MONGO_PORT=27017
      - MONGO_DBNAME=MONGO_DBNAME
      - MEM_LIMIT=1024 #optional
      - MEM_STARTUP=1024 #optional
      - MONGO_TLS= #optional
      - MONGO_AUTHSOURCE= #optional
    volumes:
      - ../Docker-Files:/config
    ports:
      - 8443:8443
      - 3478:3478/udp
      - 10001:10001/udp
      - 8080:8080
      - 1900:1900/udp #optional
      - 8843:8843 #optional
      - 8880:8880 #optional
      - 6789:6789 #optional
      - 5514:5514/udp #optional
    restart: always
    networks:
      - unifi-network
networks:
  unifi-network:
    external: true

So that the mongodb database should only be accesible from the Unifi Container I have created a new network where I have put both container inside.