|
Hello, When I first set up Immich some months ago I used a docker compose that pulled this postgres image: tensorchord/pgvecto-rs:pg16-v0.2.1. I am now trying to revert to the official compose, but none of the images seem to work. I think it's because I need to do a clean migration but I honestly have no idea how to do that.
The initial image does work with Immich 2.7.5 but I'm concerned that staying on that old version will break something down the line someday. Thank you! |
Replies: 3 comments 7 replies
|
You should first use 16-vectorchord0.5.3-pgvector0.8.1 If it doesn't work, please post your logs. |
|
Thanks a lot @Mraedis , this helped me a lot migrating mine! 👌😉 |
|
For anyone still wedged here because no image ships both vchord 0.5.3 and pgvecto.rs at once — I built a disposable bridge image that gets you across, and wrote up the full runbook. (This is the gap @Mraedis noted above; the pgvecto.rs-bearing images cap at vchord 0.4.2, so once your DB is at vchord 0.5.3 you can't boot anything that still needs The wedge
You need one image with both, just long enough to reindex off pgvecto.rs onto VectorChord, then drop pgvecto.rs and move to a clean image. The image
It's the official Dockerfile# Stage that still contains pgvecto.rs (vectors.so + its extension files)
FROM ghcr.io/immich-app/postgres:16-vectorchord0.4.2-pgvector0.8.1-pgvectors0.2.1 AS bridge
# Final image: has vchord 0.5.3 (satisfies the DB) + pgvector, but NO pgvecto.rs
FROM ghcr.io/immich-app/postgres:16-vectorchord0.5.3-pgvector0.8.1
# Bring pgvecto.rs across: the loadable library + its extension control/SQL files.
COPY --from=bridge /usr/lib/postgresql/16/lib/vectors.so /usr/lib/postgresql/16/lib/vectors.so
COPY --from=bridge /usr/share/postgresql/16/extension/vectors* /usr/share/postgresql/16/extension/
# Fail the build immediately if any expected file is missing / paths changed.
RUN set -eux; \
test -f /usr/lib/postgresql/16/lib/vectors.so; \
test -f /usr/lib/postgresql/16/lib/vchord.so; \
ls -la /usr/share/postgresql/16/extension/vectors*; \
ls -la /usr/lib/postgresql/16/lib/vectors.so /usr/lib/postgresql/16/lib/vchord.soRunbook
|
This is embarassing but there is no vchord0.5.3 image with pgvecto.rs0.2.1 so you'll have to restore from backup to a pre-upgraded database and then go to vectorchord0.4.2-pgvector0.8.1-pgvectors0.2.1 once again, then you can go to 16-vectorchord0.5.3