Issue with connection to psql "pgvecto-rs:pg15-v0.2.0"

I'm currently trying to setup Immich on docker in a debian server. I have redis and psql15 with vector 0.2.0 on different containers in the same machine. I've set up the vector extension and gave the immich user superuser. Now, when i start the immich contaienr i get a loop with:
Starting api worker
[Nest] 2941 - 08/06/2024, 1:53:46 AM LOG [Api:EventRepository] Initialized websocket server
Migration "UsePgVectors1700713871511" failed, error: could not access file "$libdir/vector": No such file or directory
Starting api worker
[Nest] 2941 - 08/06/2024, 1:53:46 AM LOG [Api:EventRepository] Initialized websocket server
Migration "UsePgVectors1700713871511" failed, error: could not access file "$libdir/vector": No such file or directory
Checking the postgresql i can see the extension there, but its called "vectors" instead of "vector" I've been googling this for a while but all the results just mention the vector extension installation, that i already have. Is this a known issue? Is there a known way to fix it?
16 Replies
Immich
Immich11mo ago
:wave: Hey @SUB0PT1MAL, Thanks for reaching out to us. Please follow the recommended actions below; 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 compose ps docs - Reverse Proxy: https://immich.app/docs/administration/reverse-proxy Checklist 1. :ballot_box_with_check: I have verified I'm on the latest release(note that mobile app releases may take some time). 2. :ballot_box_with_check: I have read applicable release notes. 3. :ballot_box_with_check: I have reviewed the FAQs for known issues. 4. :ballot_box_with_check: I have reviewed Github for known issues. 5. :ballot_box_with_check: I have tried accessing Immich via local ip (without a custom reverse proxy). 6. :ballot_box_with_check: I have uploaded the relevant logs, docker compose, and .env files, making sure to use code formatting. 7. :ballot_box_with_check: I have 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) If this ticket can be closed you can use the /close command, and re-open it later if needed.
Immich
Immich11mo ago
Successfully submitted, a tag has been added to inform contributors. :white_check_mark:
sogan
sogan11mo ago
The right extension is vectors, not vector. Are you sure you only have that installed and not vector?
SUB0PT1MAL
SUB0PT1MALOP11mo ago
yes, also, if i try to run either "CREATE EXTENSION vectors;" or "CREATE EXTENSION vector;" it says it already exists
No description
SUB0PT1MAL
SUB0PT1MALOP11mo ago
This comes up if i search for files containing "vector"
/sys/module/kvm/parameters/vector_hashing
/usr/lib/postgresql/15/lib/bitcode/postgres/utils/adt/tsvector.bc
/usr/lib/postgresql/15/lib/bitcode/postgres/utils/adt/tsvector_op.bc
/usr/lib/postgresql/15/lib/bitcode/postgres/utils/adt/tsvector_parser.bc
/usr/lib/postgresql/15/lib/vectors.so
/usr/share/doc/vectors-pg15
/usr/share/postgresql/15/extension/vectors--0.1.0--0.1.1.sql
/usr/share/postgresql/15/extension/vectors--0.1.1--0.1.2.sql
/usr/share/postgresql/15/extension/vectors--0.1.10--0.1.11.sql
/usr/share/postgresql/15/extension/vectors--0.1.11--0.2.0.sql
/usr/share/postgresql/15/extension/vectors--0.1.12--0.1.13.sql
/usr/share/postgresql/15/extension/vectors--0.1.13--0.2.0.sql
/usr/share/postgresql/15/extension/vectors--0.1.2--0.1.3.sql
/usr/share/postgresql/15/extension/vectors--0.1.3--0.1.4.sql
/usr/share/postgresql/15/extension/vectors--0.1.4--0.1.5.sql
/usr/share/postgresql/15/extension/vectors--0.1.5--0.1.6.sql
/usr/share/postgresql/15/extension/vectors--0.1.6--0.1.7.sql
/usr/share/postgresql/15/extension/vectors--0.1.7--0.1.8.sql
/usr/share/postgresql/15/extension/vectors--0.1.8--0.2.0.sql
/usr/share/postgresql/15/extension/vectors--0.1.9--0.1.10.sql
/usr/share/postgresql/15/extension/vectors--0.2.0.sql
/usr/share/postgresql/15/extension/vectors.control
/var/lib/dpkg/info/vectors-pg15.list
/var/lib/dpkg/info/vectors-pg15.md5sums
/var/lib/postgresql/data/pg_vectors
/var/lib/postgresql/data/pg_vectors/indexes
/var/lib/postgresql/data/pg_vectors/startup
/var/lib/postgresql/data/pg_vectors/startup/0
/var/lib/postgresql/data/pg_vectors/VERSION
/sys/module/kvm/parameters/vector_hashing
/usr/lib/postgresql/15/lib/bitcode/postgres/utils/adt/tsvector.bc
/usr/lib/postgresql/15/lib/bitcode/postgres/utils/adt/tsvector_op.bc
/usr/lib/postgresql/15/lib/bitcode/postgres/utils/adt/tsvector_parser.bc
/usr/lib/postgresql/15/lib/vectors.so
/usr/share/doc/vectors-pg15
/usr/share/postgresql/15/extension/vectors--0.1.0--0.1.1.sql
/usr/share/postgresql/15/extension/vectors--0.1.1--0.1.2.sql
/usr/share/postgresql/15/extension/vectors--0.1.10--0.1.11.sql
/usr/share/postgresql/15/extension/vectors--0.1.11--0.2.0.sql
/usr/share/postgresql/15/extension/vectors--0.1.12--0.1.13.sql
/usr/share/postgresql/15/extension/vectors--0.1.13--0.2.0.sql
/usr/share/postgresql/15/extension/vectors--0.1.2--0.1.3.sql
/usr/share/postgresql/15/extension/vectors--0.1.3--0.1.4.sql
/usr/share/postgresql/15/extension/vectors--0.1.4--0.1.5.sql
/usr/share/postgresql/15/extension/vectors--0.1.5--0.1.6.sql
/usr/share/postgresql/15/extension/vectors--0.1.6--0.1.7.sql
/usr/share/postgresql/15/extension/vectors--0.1.7--0.1.8.sql
/usr/share/postgresql/15/extension/vectors--0.1.8--0.2.0.sql
/usr/share/postgresql/15/extension/vectors--0.1.9--0.1.10.sql
/usr/share/postgresql/15/extension/vectors--0.2.0.sql
/usr/share/postgresql/15/extension/vectors.control
/var/lib/dpkg/info/vectors-pg15.list
/var/lib/dpkg/info/vectors-pg15.md5sums
/var/lib/postgresql/data/pg_vectors
/var/lib/postgresql/data/pg_vectors/indexes
/var/lib/postgresql/data/pg_vectors/startup
/var/lib/postgresql/data/pg_vectors/startup/0
/var/lib/postgresql/data/pg_vectors/VERSION
sogan
sogan11mo ago
Try DROP EXTENSION vector;
SUB0PT1MAL
SUB0PT1MALOP11mo ago
i did several times, Immich recreates it as soon as it gets started or the next time it loops if left running when performing the DROP I just did it again, same result
sogan
sogan11mo ago
Could you start with a fresh clean DB? This isn’t making any sense
SUB0PT1MAL
SUB0PT1MALOP11mo ago
Sure, but this is a brand new db created for immich. Give me a minute
Zeus
Zeus11mo ago
can you post your docker-compose and .env? how did you prepare your database?
SUB0PT1MAL
SUB0PT1MALOP11mo ago
I decided to delete the vector index before nuking the db, and would you believe it, it now works I guess that deleting the extension and schema does not delete the indexes? anyhow, issue solved.
sogan
sogan11mo ago
Huh, that’s interesting. Glad you got it working!
SUB0PT1MAL
SUB0PT1MALOP11mo ago
Thanks to you!!
sogan
sogan11mo ago
No problem!
Manuel Rais (CTO TNZPV)
hi ! I've got the exact same problem. How can I delete the vector index ? Sorry, pb fixed, iI was using the wrong psql image

Did you find this page helpful?