EOFException when connecting to local Postgres in DBeaver
Asked Answered
R

2

5

I'm having troubles when trying to connect to local docker postgres db. I have spun up a new postgres db container on port 5434 which I can confirm is successfully running. I have added the docker ps command response below. For some reason when trying to connect to the new 5434 port though on DbBeaver I just get the following error EOFException. I've also attached image of that below.

Don't really understand what is happening, as I'm certain I'm putting in correct auth details, and I have tried multiple times on other ports, but only connection to 5432 works. Anyone know how to get another port working?

enter image description here

enter image description here

Rinse answered 16/6, 2022 at 0:38 Comment(2)
That the container is running doesn't necessarily mean the database is. What do you see in the db server's log file?Nankeen
Do you have a wrong port mapping in your conf file? (5434:5434 leads to this error; it should be 5434:5432)Labelle
W
6

I faced with the same issue and my port was as 5431:5431 since I was using different postgre server on 5432:5432 port. However I resolved this problem by changing my port as 5431:5432. You probably had the same port problem.

Wigan answered 27/6, 2023 at 15:28 Comment(3)
thank you, it also works for me, but do you know why is it so?Armyn
Same, it works but I'm unsure why is it that the same port causes this issueLyse
The reason is that this mapping 5431:5432 (left is the local host and right is the container) maps the local host to the container where postgre is running. This ensures that the correct mapping is satisfied as postgre inside the container is waiting for a connection on its container port which is 5432. And the problem on the dbeaver side was because of the wrong port mapping where the port of the host wasn't correctly mapped to this expected container port of postgre. So it is all about correct port mapping.Wigan
V
0

We realized the Host address was not complete e.g. my correct url is rd1.n2.stackoverflow.com, and I had entered rd1.stackoverflow.com. Correcting it, we were able to solve our EOFException.

Verb answered 17/4, 2024 at 21:18 Comment(0)

© 2022 - 2025 — McMap. All rights reserved.