Immich App Update to 2.6.0 fails with Postress Error

I use both truenas and immich, but… i did not deploy immich using the truenas apps.

instead… i did it via dockge (installed via truenas apps), docker compose.

so, i can’t do the postgress update like u guys….

i checked around and this was what immich said

alextran1502
2 weeks ago
Maintainer

We are planning to have a proper migration to pg18 soon. So it’s better to wait until then

So i am waiting.

Right now i am using the docker compose that is the latest on immich, and that uses the OLDER posgres.

I did try to delete the older posgress folder after first stopping the container, then change posgress database to v18 vector, but that didn’t work. So i will have to wait for that update the maintainer mentioned.

I think there may be a way to do it, but from what AI said, you had to start the posgres in a temporary location to avoid it from not running due to error, so that you can run the command (the possible fix), then moving it back to start fully. But that is just way more than i can do, so i’ll just wait.

Last resort is just sticking to the truenas app install method.

So if you are in a similar situation, just wait. the update for this from immich side is coming soon. So hopefully that means they will update immich and the docker compose (which includes the posgress v18) and it will just run without issue. At the very least you may have to delete the posgres database and start from scratch, but i am ok with that as long as it runs.

*update

this is the posgres v18 with the pgvector, this is the one i tried to use but immich current version wouldn’t accept as is

http://ghcr.io/immich-app/postgres:18-vectorchord0.5.3-pgvector0.8.1

As for the possible fix i mentioned, i was referring to this specifically. I don’t know if it would actually work or not, but it was a lead

But the problem why i couldn’t do that, was because i use docker compose which has immich, posgres all loaded up in the same docker compose. so posgres would fail to start up… so… i could not run the commands with that possible fix.

asking ai, they mentioned u had to run that thing in a temporary space to get around a container not running due to error. that’s as far i got. Didn’t want to do stuff i’m not too certain about to avoid creating issues. hence why i am waiting ^^;

2 Likes

The Main Problem here is you get no advice that you have to make an Upgrade.

I stumbled across the Truenas App catalog Page by chance And saw that Immich needs a Data Base Update. the same goes for a few other Apps. why isn’t This Shown in the Truenas Web Interface?

Immich PostgreSQL 15 → 18 Upgrade Workaround (TrueNAS)

If your Immich app fails to upgrade PostgreSQL with an error like:

Old PostgreSQL [15] binaries not found

:warning: Before you start

Create a recursive snapshot of your Immich datasets so you can roll
back if needed.


:wrench: Steps

1. Stop Immich

TrueNAS → Apps → Immich → Stop


2. Find your Immich chart version (important)

Go to:

TrueNAS → Apps → Immich → Version

:backhand_index_pointing_right: Use the value shown as Version
:red_exclamation_mark: Do NOT use App version

Example:

Version: 1.13.6   ← use this
App version: v2.5.6   ← ignore this

3. Edit ix_values.yaml

sudo nano /mnt/.ix-apps/app_configs/immich/versions/<VERSION>/ix_values.yaml

Find:

postgres_upgrade_image:
  repository: ixsystems/postgres-upgrade
  tag: 1.2.1

Change to:

tag: 1.1.11

4. Upgrade PostgreSQL (15 → 18)

TrueNAS → Apps → Immich → Edit
Change:

Postgres Image: 15 → 18

Save.


5. Start Immich (if needed)

Wait 10–30 seconds.
If it doesn’t start automatically, start it manually.


6. Wait for migration

(Optional) Check logs:

docker logs -f ix-immich-pgvecto-1

7. Verify Immich

Confirm everything works: - login - photos - albums - metadata


8. Revert the workaround

Stop Immich again.

sudo nano /mnt/.ix-apps/app_configs/immich/versions/<VERSION>/ix_values.yaml

Change:

tag: 1.1.11 → 1.2.1

9. Start Immich

Start the app again and verify everything still works.


10. Update Immich

Update the app via TrueNAS to the latest version.


:brain: Notes

  • The issue is caused by postgres-upgrade:1.2.1
  • Version 1.1.11 uses a working upgrade path
  • This workaround is temporary and safe when reverted afterward

This is the way.

You’ll fart around for ages with other methods and trying not to take this nuclear approach but end up doing it anyway.

It now works for me. The problem I first did was when I copied the 15 folder I’ve let it in the postgres-data folder which blocked for me because Postgres scans every folder in that folder and so he still saw the postgres 15 data. So DO NOT put the backup in that folder.

You also need to destroy the new postgres database because you can’t dump your data in the new one because of that.

Thanks for the guide.

Thank you. This worked for me as well and was much easier than some of the above solutions.

1 Like

It worked, thank you!

1 Like

what happened if I do not have this verion? My current verison is 1.10.x, i dont see 1.13.6 as an option to upgrade

My guess is that you’re on a very outdated version of TrueNAS that is still using the old, unmaintained apps library. You’ll need to update to 25.04 at least and manually reinstall your apps. If you do some searching around the forum you should find some threads around migrating.