linuxserver / docker-unifi-network-application

GNU General Public License v3.0
551 stars 40 forks source link

[BUG] Can't update past 8.0.26 #82

Closed yavinmaster closed 1 day ago

yavinmaster commented 2 months ago

Is there an existing issue for this?

Current Behavior

I originally installed 8.0.24 and tried to updated to the current version (8.1.113) but it keeps rebooting. I have stepped through the version and have been able to update to 8.0.26 but when I update to 8.0.28 I get the same behaviour as when trying to update to 8.1.113.

The log file keeps repeating org.tuckey.web.filters.urlrewrite.UrlRewriteFilter INFO: destroy called

Expected Behavior

Update to latest docker image with a pull and up command.

Steps To Reproduce

If I edit the docker compose with a tag of newer than 8.0.26 the system fails to start after performing a docker compose pull and up -d.

Environment

- OS: Debian 6.1.0-11-amd64 (running as a virtual machine within Unraid)
- How docker service was installed: via the distro's packagemanager.

CPU architecture

x86-64

Docker creation

unifi-db:
    image: docker.io/mongo:4.4.26
    container_name: unifi-db
    volumes:
      - /mnt/appdata/IOT/unifi-network-app:/data/db
      - /mnt/appdata/IOT/unifi-network-app/init-mongo.js:/docker-entrypoint-initdb.d/init-mongo.js:ro
    restart: unless-stopped

  unifi-network-application:
    image: lscr.io/linuxserver/unifi-network-application:8.0.28
    container_name: unifi-network-application
    environment:
      - PUID=1000
      - PGID=1000
      - TZ=Etc/UTC
      - MONGO_USER=unifi
      - MONGO_PASS=xxxxx(removed)
      - MONGO_HOST=unifi-db
      - MONGO_PORT=27017
      - MONGO_DBNAME=unifi
      - MEM_LIMIT=1024 #optional
      - MEM_STARTUP=1024 #optional
      - MONGO_TLS= #optional
      - MONGO_AUTHSOURCE= #optional
    volumes:
      - /mnt/appdata/IOT/unifi-network-app:/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: unless-stopped

Container logs

[migrations] started
[migrations] no migrations found
───────────────────────────────────────

      ██╗     ███████╗██╗ ██████╗
      ██║     ██╔════╝██║██╔═══██╗
      ██║     ███████╗██║██║   ██║
      ██║     ╚════██║██║██║   ██║
      ███████╗███████║██║╚██████╔╝
      ╚══════╝╚══════╝╚═╝ ╚═════╝

   Brought to you by linuxserver.io
───────────────────────────────────────

To support LSIO projects visit:
https://www.linuxserver.io/donate/

───────────────────────────────────────
GID/UID
───────────────────────────────────────

User UID:    1000
User GID:    1000
───────────────────────────────────────

[custom-init] No custom files found, skipping...
org.tuckey.web.filters.urlrewrite.UrlRewriteFilter INFO: destroy called
org.tuckey.web.filters.urlrewrite.UrlRewriteFilter INFO: destroy called
org.tuckey.web.filters.urlrewrite.UrlRewriteFilter INFO: destroy called
org.tuckey.web.filters.urlrewrite.UrlRewriteFilter INFO: destroy called
github-actions[bot] commented 2 months ago

Thanks for opening your first issue here! Be sure to follow the relevant issue templates, or risk having this issue marked as invalid.

j0nnymoe commented 2 months ago

You need to investigate the logs of your server. This isn't a container bug and seems an issue with unifi itself: https://community.ui.com/questions/Unifi-Controller-keeps-crashing/539e451e-fb8c-4e52-8fa5-7acc94db4745

Check logs and potentially you might have to reinstall/restore a database.

yavinmaster commented 2 months ago

@j0nnymoe Thanks for the reply. The link you sent appears to be mainly related to large quantities of devices which I don't have. There is nothing obvious in the log files that I can see, just the repeating of "org.tuckey.web.filters.urlrewrite.UrlRewriteFilter INFO: destroy called".

I'd obviously prefer to avoid a reinstall although I might end up there.

j0nnymoe commented 2 months ago

It could be corrupted data. None the less, you need to check your actual unifi logs to see what errors are happening. This issue seems specific to your setup as no one else has reported this problem.

yavinmaster commented 2 months ago

OK - found the issue but don't understand it. I hadn't been looking far enough back in the log files and found a file access issue. I changed the owner of the volume back to 1000 (it was 999???) and was able to update to 8.0.28. I then went to update to the latest version but found the folder and contents was back to being owned by user 999. I changed it again back to 1000 and again was able to update and get the newest version working. What I don't understand is why the volume's owner permissions are being changed from 1000 to 999.

j0nnymoe commented 2 months ago

The unifi container will set the /config mount to ``` - PUID=1000

yavinmaster commented 2 months ago

Agreed - I just don't know what. The only volumes which are being affected are the unifi database and network applications. All the other volumes (for my other docker containers) remain unchanged. As an experiment, I changed the owner of the volume to 1000, then ran ls -al a few times. Within 10 seconds, it had reverted back to 999?????

LinuxServer-CI commented 1 month ago

This issue has been automatically marked as stale because it has not had recent activity. This might be due to missing feedback from OP. It will be closed if no further activity occurs. Thank you for your contributions.

drizuid commented 1 day ago

unfortunately, whatever is going on with your host system isn't an issue with the container (otherwise more than just you would encounter it). You are welcome to come on discord and seek best-effort help in #other-support, but as this is not a container issue, I will close this.