I
Immich•3d ago
itsddpanda

Immich Server fails to start

I am moving from Server Version: v1.132.3 to Latest Version: v1.144.1 I created a back up of the database and ran the restore process as outlined in the article: https://docs.immich.app/administration/backup-and-restore The only change i did was instead "gunzip --stdout "/path/to/backup/dump.sql.gz"
I ran "gunzip < "/path/to/backup/dump.sql.gz". Since then the immich server fails to start. Logs of the server:
69 Replies
Immich
Immich•3d ago
:wave: Hey @itsddpanda, Thanks for reaching out to us. Please carefully read this message and follow the recommended actions. This will help us be more effective in our support effort and leave more time for building Immich :immich:. References - Container Logs: docker compose logs docs - Container Status: docker ps -a docs - Reverse Proxy: https://immich.app/docs/administration/reverse-proxy - Code Formatting https://support.discord.com/hc/en-us/articles/210298617-Markdown-Text-101-Chat-Formatting-Bold-Italic-Underline#h_01GY0DAKGXDEHE263BCAYEGFJA Checklist I have... 1. :blue_square: verified I'm on the latest release(note that mobile app releases may take some time). 2. :blue_square: read applicable release notes. 3. :blue_square: reviewed the FAQs for known issues. 4. :blue_square: reviewed Github for known issues. 5. :blue_square: tried accessing Immich via local ip (without a custom reverse proxy). 6. :blue_square: uploaded the relevant information (see below). 7. :blue_square: tried an incognito window, disabled extensions, cleared mobile app cache, logged out and back in, different browsers, etc. as applicable (an item can be marked as "complete" by reacting with the appropriate number) Information In order to be able to effectively help you, we need you to provide clear information to show what the problem is. The exact details needed vary per case, but here is a list of things to consider: - Your docker-compose.yml and .env files. - Logs from all the containers and their status (see above). - All the troubleshooting steps you've tried so far. - Any recent changes you've made to Immich or your system. - Details about your system (both software/OS and hardware). - Details about your storage (filesystems, type of disks, output of commands like fdisk -l and df -h). - The version of the Immich server, mobile app, and other relevant pieces. - Any other information that you think might be relevant. Please paste files and logs with proper code formatting, and especially avoid blurry screenshots. Without the right information we can't work out what the problem is. Help us help you ;) If this ticket can be closed you can use the /close command, and re-open it later if needed.
itsddpanda
itsddpandaOP•3d ago
So after some digging, it seems the "database schema upgrade" has not happened and is not working any more
Mraedis
Mraedis•3d ago
You need to include any version from 133 to 136 when upgrading here, try going back to v1.136.3
itsddpanda
itsddpandaOP•2d ago
so once i do that, how will know if the database schema has happened or not???
Mraedis
Mraedis•2d ago
by reading the logs like you do now, and seeing if it starts up?
itsddpanda
itsddpandaOP•2d ago
i might not be able to figure out if the schema upgrade happened, well let me upgrade to suggested version first and will come back here if found any issues does below signifies anything? attached truncated log
Mraedis
Mraedis•2d ago
Looks okay, just a missing file @itsddpanda Is the web interface working properly?
itsddpanda
itsddpandaOP•2d ago
yes should i upgrade 1.44 now?
Mraedis
Mraedis•2d ago
Yep, go for it
itsddpanda
itsddpandaOP•2d ago
getting errors on this one, the app does not launch
Mraedis
Mraedis•2d ago
That's bizarre, did you upgrade to 1.136.3 and then this?
itsddpanda
itsddpandaOP•2d ago
no directly to 1.444 the env file is set to release so anytime i do it, it goes for latest one i had manually switch it over to 1.133
Mraedis
Mraedis•2d ago
Did you miss my comment here? first upgrade to v1.136.3 succesfully and then to latest otherwise you'll keep getting this error
itsddpanda
itsddpandaOP•2d ago
i thought you said any version between 133 to 136, thus i went to v1.133.1. Did not realise it has to be 136.1 will do it now
Mraedis
Mraedis•2d ago
no hang on @itsddpanda 133.1 is fine but did you also switch out to the postgres image in the compose?
itsddpanda
itsddpandaOP•2d ago
ok
Mraedis
Mraedis•2d ago
I advise v1.136.3 for a reason
itsddpanda
itsddpandaOP•2d ago
switch out to the postgres image? what is that sorry. English not my first language. I did: 1. docker compose down -v 2. docker compose pull
docker compose create
docker start immich_postgres sleep 10 3. Restore backup: gunzip < "/mnt/photos/backups/immich-db-backup-1759197600001.sql.gz" | sed "s/SELECT pg_catalog.set_config('search_path', '', false);/SELECT pg_catalog.set_config('search_path', 'public, pg_catalog', true);/g" | docker exec -i immich_postgres psql --dbname=postgres --username=postgres 4. docker compose up -d is the postgres image changed? is that what you mean
Mraedis
Mraedis•2d ago
You need to make sure to apply the breaking changes from the release(s) you're upgrading over https://github.com/immich-app/immich/discussions?discussions_q=label%3Achangelog%3Abreaking-change+sort%3Adate_created One of the changes is the use of vectorchord over pgvectors For instance, if you currently have pg14+pgvectors0.2.0 you could use ghcr.io/immich-app/postgres:14-vectorchord0.4.3-pgvectors0.2.0 for the database image
itsddpanda
itsddpandaOP•2d ago
ok current: database: container_name: immich_postgres image: docker.io/tensorchord/pgvecto-rs:pg14-v0.2.0@sha256:90724186f0a3517cf6914295b5ab410db9ce23190a2d9d0b9dd6463e3fa298f0 new: database: container_name: immich_postgres image: ghcr.io/immich-app/postgres:14-vectorchord0.4.3-pgvectors0.2.0@sha256:41eacbe83eca995561fe43814fd4891e16e39632806253848efaf04d3c8a8b84 i need to change to new? yes for v1.136.1
Mraedis
Mraedis•2d ago
Yes, but look over the rest of the compose in the release as well there are minor changes
itsddpanda
itsddpandaOP•2d ago
ok i see redis image also changed: new: redis: container_name: immich_redis image: docker.io/valkey/valkey:8-bookworm@sha256:fea8b3e67b15729d4bb70589eb03367bab9ad1ee89c876f54327fc7c6e618571 current: redis: container_name: immich_redis image: docker.io/redis:6.2-alpine@sha256:eaba718fecd1196d88533de7ba49bf903ad33664a92debb24660a922ecd9cac8 Question: now we do not expose ports of DB?
Mraedis
Mraedis•2d ago
Never did? They are on the internal network
itsddpanda
itsddpandaOP•2d ago
i must have done it for some reason. ok. noted.
Mraedis
Mraedis•2d ago
May have been from a really old version and you just never removed it 🙂
itsddpanda
itsddpandaOP•2d ago
could be. as i said i was just running those commands and it was all set. By the way I love this app. and a supporter
itsddpanda
itsddpandaOP•2d ago
itsddpanda
itsddpandaOP•2d ago
I used 1.133.1 docker compose file to get correct, redis and postgress images should i just create this directory? i checked the file (and thus the folder) is there why is throwing error...
Mraedis
Mraedis•2d ago
Could you post your compose and env please
itsddpanda
itsddpandaOP•2d ago
sure, compose and .env attached
itsddpanda
itsddpandaOP•2d ago
folders too
No description
itsddpanda
itsddpandaOP•2d ago
does this help?
Mraedis
Mraedis•2d ago
Yes 🙂 You've applied the compose of 1.137 and later on a 1.133 version Change - ${UPLOAD_LOCATION}:/data back to - ${UPLOAD_LOCATION}:/usr/src/app/upload and wait to change it until 137 or later Sorry btw it's lunchtime here so I will be disappearing intermittently
itsddpanda
itsddpandaOP•2d ago
np 🙂 what a silly error so that was it i got to change anything else now? or wait for it do some migration?
Mraedis
Mraedis•2d ago
Did the container start up now? From the logs I think the migrations have already finished
itsddpanda
itsddpandaOP•2d ago
Yes it did app is running sorry wait phone app may have an issue sync / backup not happening
itsddpanda
itsddpandaOP•2d ago
2025-10-01 16:52:38.633062 | warning | SyncLinkedAlbumService | No linked remote album ID found for local album: Snapseed | 2025-10-01 16:52:38.632871 | warning | SyncLinkedAlbumService | No linked remote album ID found for local album: Camera | what to do now?
Mraedis
Mraedis•2d ago
If these are logs from the app, make sure the app is up to date, then log out and back in
itsddpanda
itsddpandaOP•2d ago
did that already mobile app is upto date i logged out and back in just to summarise i am on v1.133.1, server works ok, web app works ok. Mobile app does not. it is updated and i signed out and loged in again should i create a new mount for immich and start a fresh? then later add the old folder as external library???
itsddpanda
itsddpandaOP•2d ago
i am a bit worried since i got a ton of stuff on it
No description
Mraedis
Mraedis•2d ago
you should move forward to latest your app is on latest, server is not, that will break app sync until server catches up @itsddpanda
itsddpanda
itsddpandaOP•2d ago
so that would mean, new postgres server, new redis server and ${UPLOAD_LOCATION}:/data anything else i am missing
Mraedis
Mraedis•2d ago
No, that should be it 🙂 You might want to do docker compose down -v this time @itsddpanda because the redis volume has made things annoying in the past or if you don't want to re-download the ML cache, you can do a normal compose down and remove only the specific redis volume
itsddpanda
itsddpandaOP•2d ago
docker compose down -v noted i should restore the backup though - right?
Mraedis
Mraedis•2d ago
... no? Are you restoring the backup every time?
itsddpanda
itsddpandaOP•2d ago
yes the postgres back
Mraedis
Mraedis•2d ago
You should only do that once, because it was broken by advancing too far
itsddpanda
itsddpandaOP•2d ago
so no restore this time?
Mraedis
Mraedis•2d ago
The rest of the upgrade process doesn't require restoring
itsddpanda
itsddpandaOP•2d ago
what to do this time, restore or no
Mraedis
Mraedis•2d ago
no
itsddpanda
itsddpandaOP•2d ago
ok so down -v and up -d straight forward
Mraedis
Mraedis•2d ago
no no don't forget to pull well I guess you technically don't need that step but it saves on downtime 🤔
itsddpanda
itsddpandaOP•2d ago
i mean if i do "docker compose up -d" it will pull since i changed the version
Mraedis
Mraedis•2d ago
A "normal" proper upgrade is simply: docker compose pull && docker compose up -d In this case docker compose pull && docker compose down -v && docker compose up -d Yeah, I just mean if you pull before up then it saves on downtime 🙂
itsddpanda
itsddpandaOP•2d ago
gotcha just pulled the images fingers crossed Yes it worked server is up and running - i did not had to do the restore of back up as well checking mobile now that worked too thank you you have been very patient and helpful. Appreciate it!
Mraedis
Mraedis•2d ago
No problem, enjoy
itsddpanda
itsddpandaOP•2d ago
can you for my understanding, what did i do wrong - except jumping directly to latest (without reading notes) and for future should i restore back up or not? coz that is how i usually upgrade
Mraedis
Mraedis•2d ago
That's all
itsddpanda
itsddpandaOP•2d ago
down -v up -d
Mraedis
Mraedis•2d ago
It's never necessary, unless you've run into trouble
itsddpanda
itsddpandaOP•2d ago
ah
Mraedis
Mraedis•2d ago
the down -v is only in this special case btw, don't do it in the future
itsddpanda
itsddpandaOP•2d ago
got it. so --force -recreate?
Mraedis
Mraedis•2d ago
redis -> valkey is sometimes annoying if the volume somehow survives why force? 👀
itsddpanda
itsddpandaOP•2d ago
my bad trying to think alternatives to my usual practice simply - pull and up - will do

Did you find this page helpful?