#Error: connect ECONNREFUSED 127

1 messages ยท Page 1 of 1 (latest)

nova coral
#

Woke up today and my immich server is not able to talk to redis

raw cedarBOT
#

:wave: Hey @nova coral,

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

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.

nova coral
#

Error: connect ECONNREFUSED 172.19.0.3:6379
at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1610:16) {
errno: -111,
code: 'ECONNREFUSED',
syscall: 'connect',
address: '172.19.0.3',
 port: 6379
}

#

using the default compose for portainer, tried to update the redis image, but no fix there

#

root@raw cedar:~# curl 172.19.0.3:6379
curl: (7) Failed to connect to 172.19.0.3 port 6379 after 0 ms: Couldn't connect to server

#

i can ping the docker ip from the lxc container

raw cedarBOT
river lotus
#

You have not provided all the information

#

Also, docker doesn't just break overnight. You'd need to tell us what you've done/if there are auto-updates/etc

nova coral
#

I can't paste the compose since i dont have nitro, but i have used a text compare to the current one available, and it matches

#

only thing i do overnight is a stop, backup the lxc, and start it

#

and have done that many times before without any issues

river lotus
#

You don't need nitro for that? ๐Ÿ‘€

nova coral
#

can i upload a .txt file ?

river lotus
#

Yes

nova coral
#

one sec

river lotus
#

You can also upload a yml file

#

Or wrap it in code blocks

#

Also, the redis logs would be interesting

nova coral
#

redis logs are empty when i download from portainer, or try viewing it

river lotus
#

Unrelated, but why's your redis port exposed?

nova coral
#

no, all local

nova coral
frosty mango
#

This part is not in the default setup

river lotus
#

Which exposes it on the host

nova coral
#

that was me trying any things

#

usually is not there, and also has the health check

#

i tried a few things before asking for help

#

new image, deleting the pod, re deploying, rebooting...

river lotus
#

Those are things you should mention at first

nova coral
#

my bad

river lotus
nova coral
#

root@raw cedar:~# telnet 172.19.0.3 6379
Trying 172.19.0.3...
telnet: Unable to connect to remote host: Connection refused

river lotus
#

So that port is indeed not open/exposed

nova coral
#

the default compose doesn't have the ports, does it make any difference ?

river lotus
#

You definitely don't need them

#

It is annoying that you don't get any redis logs

#

I feel like there must be something going wrong

nova coral
#

not even joking lol

river lotus
#

Can you try bringing down redis, deleting the docker volume it's using, and bringing it back up?

nova coral
#

yeah, one sec

#

want me to change anything in the compose while i am at it ?

river lotus
#

You can remove the ports again

#

Not sure what else you changed

nova coral
#

image

#

from redis 6.2 to 7.4

#

i will change it back to 6.2

river lotus
#

Idk if redis had breaking changes (I doubt it)

#

Yeah just do that

nova coral
#

re-deploying now

#

still no logs

river lotus
#

Is it working though?

#

Restart Immich?

nova coral
#

`Error: connect ECONNREFUSED 172.19.0.5:6379

at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1610:16) {

errno: -111,

code: 'ECONNREFUSED',

syscall: 'connect',

address: '172.19.0.5',

๏ฟฝ๏ฟฝ๏ฟฝ๏ฟฝ๏ฟฝ๏ฟฝ
port: 6379

}

[Nest] 7 - 11/27/2024, 9:40:59 PM LOG [NestFactory] Starting Nest application...

[Nest] 7 - 11/27/2024, 9:40:59 PM ERROR [TypeOrmModule] Unable to connect to the database. Retrying (1)...`

nova coral
#

saying cant connect to the DB but the ip is from redis

river lotus
#

Wait yeah that's the weird thing

#

Is your database up?

#

And pelase also share your env file

#

(and there are also multi line code blocks ;))

nova coral
#

UPLOAD_LOCATION=/root/immich-data/library DB_DATA_LOCATION=/root/immich-data/postgres IMMICH_VERSION=release DB_PASSWORD=postgres DB_USERNAME=postgres DB_DATABASE_NAME=immich DUMP_LOCATION=/root/immich-data/db_dumps

nova coral
nova coral
river lotus
nova coral
#

root@immich:~/immich-data/postgres/log# cat postgresql-2024-11-27_000000.log 2024-11-27 09:14:45.941 UTC [1] LOG: received fast shutdown request 2024-11-27 09:14:46.026 UTC [1] LOG: aborting any active transactions 2024-11-27 09:14:46.037 UTC [1] LOG: background worker "logical replication launcher" (PID 34) exited with exit code 1 2024-11-27 09:14:46.052 UTC [29] LOG: shutting down 2024-11-27 09:14:46.978 UTC [1] LOG: database system is shut down

river lotus
#

Yeah so your database isn't up

#

What makes you say it is up?

nova coral
#

it shows as unhealthy in postgres

frosty mango
#

What system are you running on, what sort of specs does it have?

nova coral
#

lxc container in proxmox

#

4cpus
8gb ram
8gb swap
258gb hdd

#

even tried to restore yesterdays backup, which didn't fix the problem, starting to think it is a proxmox issue

frosty mango
#

docker in lxc is unsupported and can run into weird issues

nova coral
#

time to copy all images lol

river lotus
#

Docker :P

nova coral
#

isn't lxc just an enviroment where docker runs on top of ?

river lotus
#

Correct, that's nested containerization

nova coral
#

i will delete the stack, delete all images, and redeploy the stack, if that doesnt work, this sounds like a next week problem for me

river lotus
#

At least you have backups, right?

#

That's definitely good ๐Ÿ˜…

nova coral
#

yeah, just a pain to move them lol

river lotus
#

Fair enough

nova coral
#

one back up is a ssd, another one is somewhere in the server, and another one is lost lmao

nova coral
#

I Fu** fixed it hehe

#

It was the swap memory, I disabled that, rebooted the server, and now it is working

#

why? dunno, dont care lol

river lotus
#

You usually don't want to have swap disabled completely fwiw

nova coral
#

next weeks problem to figure out