immich-app / immich

High performance self-hosted photo and video management solution.
https://immich.app
GNU Affero General Public License v3.0
49.39k stars 2.6k forks source link

Immich server crashes on startup after upgrading to version v1.108.0 #11119

Closed jtamm-red closed 3 months ago

jtamm-red commented 3 months ago

The bug

Machine: NanoPi R5C 8GB, 512GB NVMe

Docker container's logs:

Node.js v20.15.1
Detected CPU Cores: 8
/usr/src/app/node_modules/sharp/lib/sharp.js:114
  throw new Error(help.join('\n'));
  ^

Error: Could not load the "sharp" module using the linux-arm64 runtime
ERR_DLOPEN_FAILED: libwebpdemux.so.2: cannot open shared object file: No such file or directory
Possible solutions:
- Ensure optional dependencies can be installed:
    npm install --include=optional sharp
    yarn add sharp --ignore-engines
- Ensure your package manager supports multi-platform installation:
    See https://sharp.pixelplumbing.com/install#cross-platform
- Add platform-specific dependencies:
    npm install --os=linux --cpu=arm64 sharp
- Consult the installation documentation:
    See https://sharp.pixelplumbing.com/install
    at Object.<anonymous> (/usr/src/app/node_modules/sharp/lib/sharp.js:114:9)
    at Module._compile (node:internal/modules/cjs/loader:1358:14)
    at Module._extensions..js (node:internal/modules/cjs/loader:1416:10)
    at Module.load (node:internal/modules/cjs/loader:1208:32)
    at Module._load (node:internal/modules/cjs/loader:1024:12)
    at Module.require (node:internal/modules/cjs/loader:1233:19)
    at require (node:internal/modules/helpers:179:18)
    at Object.<anonymous> (/usr/src/app/node_modules/sharp/lib/constructor.js:10:1)
    at Module._compile (node:internal/modules/cjs/loader:1358:14)
    at Module._extensions..js (node:internal/modules/cjs/loader:1416:10)

Could you provide guidance or potential solutions to resolve this issue?

The OS that Immich Server is running on

Linux R6C 5.10.160

Version of Immich Server

v1.108.0

Version of Immich Mobile App

*

Platform with the issue

Your docker-compose.yml content

immich-server:
    container_name: immich-server
    image: ghcr.io/immich-app/immich-server:main
    #privileged: true
    command: [ "start.sh", "immich" ]
    volumes:
      - /data/immich/upload:/usr/src/app/upload
      #- /etc/localtime:/etc/localtime:ro
    environment:
      DB_HOSTNAME: 127.0.0.1
      DB_USERNAME: immich
      DB_PASSWORD: immich
      DB_DATABASE_NAME: immich
      REDIS_HOSTNAME: 127.0.0.1
    #ports:
    #  - 2283:3001
    #depends_on:
    #  - redis
    #  - database
    restart: always
    network_mode: host

  immich-microservices:
    container_name: immich-microservices
    image: ghcr.io/immich-app/immich-server:main
    privileged: true
    # extends: # uncomment this section for hardware acceleration - see https://immich.app/docs/features/hardware-transcoding
    #   file: hwaccel.transcoding.yml
    #   service: cpu # set to one of [nvenc, quicksync, rkmpp, vaapi, vaapi-wsl] for accelerated transcoding
    command: [ "start.sh", "microservices" ]
    volumes:
      - /data/immich/upload:/usr/src/app/upload
      #- /etc/localtime:/etc/localtime:ro
    environment:
      DB_HOSTNAME: 127.0.0.1
      DB_USERNAME: immich
      DB_PASSWORD: immich
      DB_DATABASE_NAME: immich
      REDIS_HOSTNAME: 127.0.0.1
    #depends_on:
    #  - redis
    #  - database
    restart: always
    network_mode: host

  immich-machine-learning:
    container_name: immich-machine-learning
    privileged: true
    # For hardware acceleration, add one of -[armnn, cuda, openvino] to the image tag.
    # Example tag: ${IMMICH_VERSION:-release}-cuda
    image: ghcr.io/immich-app/immich-machine-learning:release-armnn
    # extends: # uncomment this section for hardware acceleration - see https://immich.app/docs/features/ml-hardware-acceleration
    #   file: hwaccel.ml.yml
    #   service: cpu # set to one of [armnn, cuda, openvino, openvino-wsl] for accelerated inference - use the `-wsl` version for WSL2 where applicable
    volumes:
      - /data/immich/model-cache:/cache
    environment:
      DB_HOSTNAME: 127.0.0.1
      DB_USERNAME: immich
      DB_PASSWORD: immich
      DB_DATABASE_NAME: immich
      REDIS_HOSTNAME: 127.0.0.1
    restart: always
    network_mode: host

Your .env content

# already env is defined in docker-componse.yml

Reproduction steps

Upgrade from v1.107.0 to v1.108.0

Relevant log output

No response

Additional information

No response

bo0tzz commented 3 months ago

image: ghcr.io/immich-app/immich-server:main

You should not be running the main branch version

Can you try if you still get this error with the default docker compose project and the release images (ie, with a new install)?

jtamm-red commented 3 months ago

I got that branch main is using only amd64. I tried put tag v1.108.0. It is working as well.

Thank you for the quick response!