500 internal error when trying to login with mobile

Hi, I recently update server to 1.79.1 and have several problems: 1. If the mobile app (v1.79.0) already logged in, everthing is fine. However, a new phone with the app same version cannot login, with therror message 500 internal error. The phone that already logged in before, now that I log out, I cannot log in again, same error (500) 2. On web app, any clip uploaded by the mobile app (when it was still logged in) will have broken thumbnail and playback. However, hovering it, and it plays (with the visual quality, i guess it plays from the encoded, not the origina). I can also download the orignal clip. Thumbnails of picture is not broken. There are some logs (LOG_LEVEL=verbose): (see comments)
16 Replies
Sinh Tran Gatech IA/NVIDIA Instr
from _server: OPError: expected 200 OK, got: 404 Not Found at processResponse (/usr/src/app/node_modules/openid-client/lib/helpers/process_response.js:41:11) at Issuer.discover (/usr/src/app/node_modules/openid-client/lib/issuer.js:179:18) at process.processTicksAndRejections (node:internal/process/task_queues:95:5) at async AuthService.getOAuthClient (/usr/src/app/dist/domain/auth/auth.service.js:245:24) at async AuthService.generateConfig (/usr/src/app/dist/domain/auth/auth.service.js:146:22) at async /usr/src/app/node_modules/@nestjs/core/router/router-execution-context.js:46:28 at async /usr/src/app/node_modules/@nestjs/core/router/router-proxy.js:9:17 [Nest] 7 - 09/27/2023, 12:31:31 AM ERROR [ExceptionsHandler] expected 200 OK, got: 404 Not Found OPError: expected 200 OK, got: 404 Not Found at processResponse (/usr/src/app/node_modules/openid-client/lib/helpers/process_response.js:41:11) at Issuer.discover (/usr/src/app/node_modules/openid-client/lib/issuer.js:179:18) at process.processTicksAndRejections (node:internal/process/task_queues:95:5) at async AuthService.getOAuthClient (/usr/src/app/dist/domain/auth/auth.service.js:245:24) at async AuthService.generateConfig (/usr/src/app/dist/domain/auth/auth.service.js:146:22) at async /usr/src/app/node_modules/@nestjs/core/router/router-execution-context.js:46:28 at async /usr/src/app/node_modules/@nestjs/core/router/router-proxy.js:9:17 from _microservice (no error or warning): [Nest] 7 - 09/27/2023, 12:30:05 AM LOG [MetadataExtractionProcessor] Reverse geocoding is enabled [Nest] 7 - 09/27/2023, 12:30:05 AM LOG [MetadataExtractionProcessor] Initializing Reverse Geocoding [Nest] 7 - 09/27/2023, 12:30:15 AM LOG [MetadataExtractionProcessor] Reverse Geocoding Initialized [Nest] 7 - 09/27/2023, 12:30:15 AM LOG [SearchService] Running bootstrap [Nest] 7 - 09/27/2023, 12:30:15 AM DEBUG [TypesenseRepository] albums-v2 collection has 3 documents [Nest] 7 - 09/27/2023, 12:30:15 AM DEBUG [TypesenseRepository] assets-v8 collection has 4262 documents [Nest] 7 - 09/27/2023, 12:30:15 AM DEBUG [TypesenseRepository] faces-v1 collection has 1862 documents [Nest] 7 - 09/27/2023, 12:30:15 AM LOG [TypesenseRepository] Schema up to date: assets/assets-v8 [Nest] 7 - 09/27/2023, 12:30:15 AM LOG [TypesenseRepository] Schema up to date: albums/albums-v2 [Nest] 7 - 09/27/2023, 12:30:15 AM LOG [TypesenseRepository] Schema up to date: faces/faces-v1  [Nest] 7 - 09/27/2023, 12:30:15 AM LOG [TypesenseRepository] Alias mapping: [{"collection_name":"faces-v1","name":"faces"},{"collection_name":"albums-v2","name":"albums"},{"collection_name":"assets-v8","name":"assets"}] [Nest] 7 - 09/27/2023, 12:30:15 AM LOG [TypesenseRepository] Collections needing migration: {"assets":false,"albums":false,"faces":false} [Nest] 7 - 09/27/2023, 12:30:15 AM LOG [NestApplication] Nest application successfully started +7ms [Nest] 7 - 09/27/2023, 12:30:15 AM LOG [ImmichMicroservice] Immich Microservices is listening on http://[::1]:3002 [v1.79.1] [PRODUCTION] I don't know where else I can debug.... FWIW, curl -L -X POST 'http://local.lan:2283/api/auth/login' \ -H 'Content-Type: application/json' \ -H 'Accept: application/json' \ works
Alex Tran
Alex Tran•2y ago
Can you login via local IP?
Sinh Tran Gatech IA/NVIDIA Instr
on mobile, using web, I can access both using local domain (local.lan) and local IP (192.168.1.107); one mobile, using app, when hitting "next", it says 500 internal server error, if I set a bogus IP (169.1.1.1), it expectedly says "server not reachable"
Alex Tran
Alex Tran•2y ago
What is the url did you put in the app? Have you made sure to have /api at the end?
Sinh Tran Gatech IA/NVIDIA Instr
with : - http://local.lan:2283 (no api at the end), 500 internal server error - http://local.lan:2283/api (api no trailing slash), 500 internal server error - http://local.lan:2283/api (api with trailing slash), 500 internal server error - http://local.lan:2283/apia (api missepelled with trailing slash), 404 not found - http://local.lan:2283/dummy (some random thing), long HTML message, also saysing page not found anyway, for any of these, where can I see log / debug? Especially for 5xx logs
Alex Tran
Alex Tran•2y ago
Are you using OAuth on Immich by chance? usually it would be in the server container, or the mobile app log
Sinh Tran Gatech IA/NVIDIA Instr
I haven't, I dont think Oauth was there in 1.72.x, but I can check to make sure there's no configuration related to that
Alex Tran
Alex Tran•2y ago
Oauth has been implemented a long time ago, probably sometimes in 2022. I saw the error message somehow comes from openid-client library, thus the question
Sinh Tran Gatech IA/NVIDIA Instr
I have tried all containers (web, server, proxy, microservices), and set LOG_LEVEL=verbose, but can't find anything related to 500,. The most I could find was 404, as posted below
Alex Tran
Alex Tran•2y ago
If you are using local IP instead of local DNS, does it work?
Sinh Tran Gatech IA/NVIDIA Instr
no, see here, btw, I also disable IPv6 for this purpose of testing/debuging.
Alex Tran
Alex Tran•2y ago
So you are using local IP, i.e 192.168.1.107 on the mobile app and it didn't work as well? What is your setup look like, is it through the provided docker-compose file?
Sinh Tran Gatech IA/NVIDIA Instr
Actually I see that I do have oauth. Let me re-test with Oauth disabled Ok, thanks, Oauth was the problem. I'm now in 😄 Though, I still have the problem with broken thumbnail for video (but not picture, and not encoded video). Shall I create an new thread focusing on that?
Alex Tran
Alex Tran•2y ago
Can it be reproducible on a clean instance? which browser have you tried? Have you try to run thumbnail generation job for missing one?
Sinh Tran Gatech IA/NVIDIA Instr
Can it be reproducible on a clean instance?
no i haven't tried that yet
which browser have you tried? Have you try to run
Chrome, Safari, and a nother phone (Android) that does not have the video locally.
Have you try to run thumbnail generation job for missing one?
Yes, I first run generate for misssing, then run for all. I also run video encoding for all, problem resists
Sinh Tran Gatech IA/NVIDIA Instr
btw, here's the recoding of how it looks, you can see there is no 4xx or 5xx errors, but thumbs still show broken https://www.youtube.com/watch?v=nAZfXCI5Qqg&feature=youtu.be
TruongSinh Tran-Nguyen
YouTube
Example of broken thumb
Example of broken thumb

Did you find this page helpful?