Pi 5 cannot run Immich because of Typesense error #1718

Closed
opened 2026-02-05 03:19:45 +03:00 by OVERLORD · 5 comments
Owner

Originally created by @vertigo2600 on GitHub (Dec 3, 2023).

The bug

Immich Server is unable to start on Pi5 because Typesense will not start.

Typesense requires a 4k page size but Rasberry Pi 5 on Debian 12 Bookworm uses 16k page size.

The issue is better described here: https://github.com/typesense/typesense/issues/1351
Including a Fix from Typsense dev kishorenc in the form of this custom build: https://dl.typesense.org/debug/0.26.0.rcjemalloc1/typesense-server-0.26.0.rcjemalloc1-linux-arm64.tar.gz

I'm not sure how to load an image directly from a tar.gz file... but I was wondering if the contents of it can be added to the Immich docker-compose.yml to solve this issue for arm64 users on Rasberry pi 5.

The OS that Immich Server is running on

Debian 12 Bookworm

Version of Immich Server

latest

Version of Immich Mobile App

latest

Platform with the issue

  • Server
  • Web
  • Mobile

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: immich

services:
  immich-server:
    container_name: immich_server
    image: ghcr.io/immich-app/immich-server:${IMMICH_VERSION:-release}
    command: [ "start.sh", "immich" ]
    volumes:
      - ${UPLOAD_LOCATION}:/usr/src/app/upload
      - /etc/localtime:/etc/localtime:ro
    env_file:
      - .env
    ports:
      - 2283:3001
    depends_on:
      - redis
      - database
      - typesense
    restart: always

  immich-microservices:
    container_name: immich_microservices
    image: ghcr.io/immich-app/immich-server:${IMMICH_VERSION:-release}
    # extends:
    #   file: hwaccel.yml
    #   service: hwaccel
    command: [ "start.sh", "microservices" ]
    volumes:
      - ${UPLOAD_LOCATION}:/usr/src/app/upload
      - /etc/localtime:/etc/localtime:ro
    env_file:
      - .env
    depends_on:
      - redis
      - database
      - typesense
    restart: always

  immich-machine-learning:
    container_name: immich_machine_learning
    image: ghcr.io/immich-app/immich-machine-learning:${IMMICH_VERSION:-release}
    volumes:
      - model-cache:/cache
    env_file:
      - .env
    restart: always

  typesense:
    container_name: immich_typesense
    image: typesense/typesense:0.25.1
    environment:
      - TYPESENSE_API_KEY=${TYPESENSE_API_KEY}
      - TYPESENSE_DATA_DIR=/data
      # remove this to get debug messages
      - GLOG_minloglevel=1
    volumes:
      - tsdata:/data
    restart: always


  redis:
    container_name: immich_redis
    image: redis:6.2-alpine@sha256:80cc8518800438c684a53ed829c621c94afd1087aaeb59b0d4343ed3e7bcf6c5
    restart: always

  database:
    container_name: immich_postgres
    image: postgres:14-alpine@sha256:50d9be76e9a90da4c781554955e0ffc79d9d5c4226838e64b36aacc97cbc35ad
    env_file:
      - .env
    environment:
      POSTGRES_PASSWORD: ${DB_PASSWORD}
      POSTGRES_USER: ${DB_USERNAME}
      POSTGRES_DB: ${DB_DATABASE_NAME}
    volumes:
      - pgdata:/var/lib/postgresql/data
    restart: always

volumes:
  pgdata:
  model-cache:
  tsdata:

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=/srv/dev-disk-by-uuid-846591cd-849f-4231-a234-f55a9fc2b29b/shared/immich


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

# Connection secrets for postgres and typesense. You should change these to random passwords
TYPESENSE_API_KEY=this_is_my_custom_immich_key
DB_PASSWORD=postgres

# 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.  Download docker-compose.yml and .env 
2.  Edit .env as discussed in install guide
3.  Run Docker Compose Up -d
4.  check logs...
5.  immich server logs, the below keeps repeating
-Request #1701582572872: Request to Node 0 failed due to "EAI_AGAIN getaddrinfo EAI_AGAIN typesense"
-Request #1701582572872: Sleeping for 4s and then retrying request...
6.  typesense server logs,  below keeps repeating
-<jemalloc>: Unsupported system page size
-<jemalloc>: Unsupported system page size
-terminate called without an active exception

Additional information

please reach out if you need anything else, I'm not sure what else to provide since the rasberry pi 5 is still so new. Unable to access the web page as immich server keeps restarting due to dependency on typesense.

Also it's my first time reporting an issue so I hope I followed the guidelines correctly

Originally created by @vertigo2600 on GitHub (Dec 3, 2023). ### The bug Immich Server is unable to start on Pi5 because Typesense will not start. Typesense requires a 4k page size but Rasberry Pi 5 on Debian 12 Bookworm uses 16k page size. The issue is better described here: https://github.com/typesense/typesense/issues/1351 Including a Fix from Typsense dev kishorenc in the form of this custom build: https://dl.typesense.org/debug/0.26.0.rcjemalloc1/typesense-server-0.26.0.rcjemalloc1-linux-arm64.tar.gz I'm not sure how to load an image directly from a tar.gz file... but I was wondering if the contents of it can be added to the Immich docker-compose.yml to solve this issue for arm64 users on Rasberry pi 5. ### The OS that Immich Server is running on Debian 12 Bookworm ### Version of Immich Server latest ### Version of Immich Mobile App latest ### Platform with the issue - [X] Server - [X] Web - [ ] Mobile ### Your docker-compose.yml content ```YAML 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: immich services: immich-server: container_name: immich_server image: ghcr.io/immich-app/immich-server:${IMMICH_VERSION:-release} command: [ "start.sh", "immich" ] volumes: - ${UPLOAD_LOCATION}:/usr/src/app/upload - /etc/localtime:/etc/localtime:ro env_file: - .env ports: - 2283:3001 depends_on: - redis - database - typesense restart: always immich-microservices: container_name: immich_microservices image: ghcr.io/immich-app/immich-server:${IMMICH_VERSION:-release} # extends: # file: hwaccel.yml # service: hwaccel command: [ "start.sh", "microservices" ] volumes: - ${UPLOAD_LOCATION}:/usr/src/app/upload - /etc/localtime:/etc/localtime:ro env_file: - .env depends_on: - redis - database - typesense restart: always immich-machine-learning: container_name: immich_machine_learning image: ghcr.io/immich-app/immich-machine-learning:${IMMICH_VERSION:-release} volumes: - model-cache:/cache env_file: - .env restart: always typesense: container_name: immich_typesense image: typesense/typesense:0.25.1 environment: - TYPESENSE_API_KEY=${TYPESENSE_API_KEY} - TYPESENSE_DATA_DIR=/data # remove this to get debug messages - GLOG_minloglevel=1 volumes: - tsdata:/data restart: always redis: container_name: immich_redis image: redis:6.2-alpine@sha256:80cc8518800438c684a53ed829c621c94afd1087aaeb59b0d4343ed3e7bcf6c5 restart: always database: container_name: immich_postgres image: postgres:14-alpine@sha256:50d9be76e9a90da4c781554955e0ffc79d9d5c4226838e64b36aacc97cbc35ad env_file: - .env environment: POSTGRES_PASSWORD: ${DB_PASSWORD} POSTGRES_USER: ${DB_USERNAME} POSTGRES_DB: ${DB_DATABASE_NAME} volumes: - pgdata:/var/lib/postgresql/data restart: always volumes: pgdata: model-cache: tsdata: ``` ### Your .env content ```Shell # 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=/srv/dev-disk-by-uuid-846591cd-849f-4231-a234-f55a9fc2b29b/shared/immich # The Immich version to use. You can pin this to a specific version like "v1.71.0" IMMICH_VERSION=release # Connection secrets for postgres and typesense. You should change these to random passwords TYPESENSE_API_KEY=this_is_my_custom_immich_key DB_PASSWORD=postgres # 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 ```bash 1. Download docker-compose.yml and .env 2. Edit .env as discussed in install guide 3. Run Docker Compose Up -d 4. check logs... 5. immich server logs, the below keeps repeating -Request #1701582572872: Request to Node 0 failed due to "EAI_AGAIN getaddrinfo EAI_AGAIN typesense" -Request #1701582572872: Sleeping for 4s and then retrying request... 6. typesense server logs, below keeps repeating -<jemalloc>: Unsupported system page size -<jemalloc>: Unsupported system page size -terminate called without an active exception ``` ### Additional information please reach out if you need anything else, I'm not sure what else to provide since the rasberry pi 5 is still so new. Unable to access the web page as immich server keeps restarting due to dependency on typesense. Also it's my first time reporting an issue so I hope I followed the guidelines correctly
Author
Owner

@jdomlac commented on GitHub (Dec 3, 2023):

For anyone trying Immich on the RPi 5, try follow these steps:

Get into the https://github.com/typesense/typesense/issues/1351 issue and get the build published by the typesense dev.

Follow these steps I described on that same issue to build a docker image from the given build.

Use that image to deploy Immich:

typesense:
    container_name: immich_typesense
-   image: typesense/typesense:0.24.1@sha256:9bcff2b829f12074426ca044b56160ca9d777a0c488303469143dd9f8259d4dd
+   image: custom/image_name
    environment:
@jdomlac commented on GitHub (Dec 3, 2023): For anyone trying Immich on the RPi 5, try follow these steps: Get into the https://github.com/typesense/typesense/issues/1351 issue and get the build published by the typesense dev. Follow [these steps](https://github.com/typesense/typesense/issues/1351) I described on that same issue to build a docker image from the given build. Use that image to deploy Immich: ```diff typesense: container_name: immich_typesense - image: typesense/typesense:0.24.1@sha256:9bcff2b829f12074426ca044b56160ca9d777a0c488303469143dd9f8259d4dd + image: custom/image_name environment: ```
Author
Owner

@Utopiah commented on GitHub (Jan 19, 2024):

As the issue is marked completed and closed, does it mean following https://immich.app/docs/install/requirements/ on a RPi5 today will work without any custom step?

@Utopiah commented on GitHub (Jan 19, 2024): As the issue is marked completed and closed, does it mean following https://immich.app/docs/install/requirements/ on a RPi5 today will work without any custom step?
Author
Owner

@jdomlac commented on GitHub (Jan 19, 2024):

Yes, it works, recent immich versions no longer depend on typesense

@jdomlac commented on GitHub (Jan 19, 2024): Yes, it works, recent immich versions no longer depend on typesense
Author
Owner

@Utopiah commented on GitHub (Jan 19, 2024):

Super, thanks for the clarification.

PS: I asked due to the "2 of 3 tasks" at the top of the issue.

@Utopiah commented on GitHub (Jan 19, 2024): Super, thanks for the clarification. PS: I asked due to the "2 of 3 tasks" at the top of the issue.
Author
Owner

@Utopiah commented on GitHub (Jan 22, 2024):

Note to people who might ask "why" bother with a Pi 5 in the first place, consider remote machine learning as described in https://immich.app/docs/guides/remote-machine-learning/

I believe it's a wonderful way to do self-hosting while staying close to the state of the art efficiently.

@Utopiah commented on GitHub (Jan 22, 2024): Note to people who might ask "why" bother with a Pi 5 in the first place, consider remote machine learning as described in https://immich.app/docs/guides/remote-machine-learning/ I believe it's a wonderful way to do self-hosting while staying close to the state of the art efficiently.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: immich-app/immich#1718