immich-app / immich

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

After update 1.9.5 image server was broken #7261

Closed ydrob closed 7 months ago

ydrob commented 7 months ago

The bug

After update 1.9.5 image server was broken, microserver and server containers stop after running. Logs are attached. server.xlsx microservices.xlsx

Screenshot_1

The OS that Immich Server is running on

synology dsm 7.2.1 u4

Version of Immich Server

v1.9.5

Version of Immich Mobile App

v1.95.0

Platform with the issue

Your docker-compose.yml content

version: "3.8"

#
# WARNING: Make sure to use the docker-compose.yml of the current release:
#
# https://github.com/immich-app/immich/releases/latest/download/docker-compose.yml
#
# The compose file on main may not be compatible with the latest release.
#

name: test_immich

services:
  immich-server:
    container_name: test_immich_server
    image: ghcr.io/immich-app/immich-server:v1.95.0
    environment:
      DB_HOSTNAME: test_immich_postgres
      REDIS_HOSTNAME: test_immich_redis
    user: 1026:100
    security_opt:
      - no-new-privileges:true
    command: [ "start.sh", "immich" ]
    volumes:
      - /volume1/docker/test_immich/upload:/usr/src/app/upload
      - /etc/localtime:/etc/localtime:ro
    env_file:
      - .env
    ports:
      - 1283:3001
    depends_on:
      - redis
      - database
    restart: unless-stopped

  immich-microservices:
    container_name: test_immich_microservices
    image: ghcr.io/immich-app/immich-server:v1.95.0
    environment:
      DB_HOSTNAME: test_immich_postgres
      REDIS_HOSTNAME: test_immich_redis
    user: 1026:100
    security_opt:
      - no-new-privileges:true
    # extends:
    #   file: hwaccel.yml
    #   service: hwaccel
    command: [ "start.sh", "microservices" ]
    volumes:
      - /volume1/docker/test_immich/upload:/usr/src/app/upload
      - /etc/localtime:/etc/localtime:ro
    env_file:
      - .env
    depends_on:
      - redis
      - database
    restart: unless-stopped

  immich-machine-learning:
    container_name: test_immich_machine_learning
    image: ghcr.io/immich-app/immich-machine-learning:v1.95.0
    environment:
      DB_HOSTNAME: test_immich_postgres
      REDIS_HOSTNAME: test_immich_redis
    user: 1026:100
    security_opt:
      - no-new-privileges:true
    volumes:
      - ./model-cache:/cache
    env_file:
      - .env
    restart: unless-stopped

  redis:
    container_name: test_immich_redis
    image: redis:6.2-alpine@sha256:b6124ab2e45cc332e16398022a411d7e37181f21ff7874835e0180f56a09e82a
    restart: unless-stopped

  database:
    container_name: test_immich_postgres
    image: tensorchord/pgvecto-rs:pg14-v0.2.0@sha256:90724186f0a3517cf6914295b5ab410db9ce23190a2d9d0b9dd6463e3fa298f0
    security_opt:
      - no-new-privileges:true
    env_file:
      - .env
    environment:
      DB_HOSTNAME: test_immich_postgres
      REDIS_HOSTNAME: test_immich_redis
      POSTGRES_PASSWORD: ${DB_PASSWORD}
      POSTGRES_USER: ${DB_USERNAME}
      POSTGRES_DB: ${DB_DATABASE_NAME}
    volumes:
      - ./pgdata:/var/lib/postgresql/data
    restart: unless-stopped

Your .env content

# You can find documentation for all the supported env variables at https://immich.app/docs/install/environment-variables

# The location where your uploaded files are stored
UPLOAD_LOCATION=/volume1/docker/test_immich/upload

# The Immich version to use. You can pin this to a specific version like "v1.71.0"
IMMICH_VERSION=v1.95.0

# Connection secret for postgres. You should change it to a random password
DB_PASSWORD=nh68MzprxILz3

# The values below this line do not need to be changed
###################################################################################
DB_HOSTNAME=immich_postgres
DB_USERNAME=postgres
DB_DATABASE_NAME=immich

REDIS_HOSTNAME=immich_redis

Reproduction steps

1.Update yaml to use version 1.9.5
2.Run project
3.
...

Additional information

No response

alextran1502 commented 7 months ago

Have you read and followed the instructions in the release note?

ydrob commented 7 months ago

Yes, I have updated versios for postgres to tensorchord/pgvecto-rs:pg14-v0.2.0@sha256:90724186f0a3517cf6914295b5ab410db9ce23190a2d9d0b9dd6463e3fa298f0 and to 1.9.5 for server, microserves and machine learning, restart containers several times.

alextran1502 commented 7 months ago

can you provide the logs?

sandroshu commented 7 months ago

postgres=# BEGIN;

CREATE SCHEMA IF NOT EXISTS vectors;
ALTER DATABASE immich SET search_path TO "$user", public, vectors;
SET search_path TO "$user", public, vectors;

UPDATE pg_catalog.pg_extension SET extversion = '0.1.11' WHERE extname = 'vectors';
UPDATE pg_catalog.pg_extension SET extrelocatable = true WHERE extname = 'vectors';
ALTER EXTENSION vectors SET SCHEMA vectors;
UPDATE pg_catalog.pg_extension SET extrelocatable = false WHERE extname = 'vectors';
ALTER EXTENSION vectors UPDATE TO '0.2.0';

SELECT pgvectors_upgrade();

COMMIT;
BEGIN
CREATE SCHEMA
ALTER DATABASE
SET
UPDATE 0
UPDATE 0
ERROR:  extension "vectors" does not exist
ERROR:  current transaction is aborted, commands ignored until end of transaction block
ERROR:  current transaction is aborted, commands ignored until end of transaction block
ERROR:  current transaction is aborted, commands ignored until end of transaction block
ROLLBACK
postgres=#