A
A
Alexey Samoilov2015-10-02 12:07:20
PostgreSQL
Alexey Samoilov, 2015-10-02 12:07:20

How to connect to Postgre server from local network?

This error occurs when connecting to the server.
33140c87f51b4acdbcd5cb5e26d5126e.png
The server is running on my local machine, the connection comes from another user on the local network. There is a ping. Everything was working yesterday. There were no changes.
What could be the problem?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
A
Azazel PW, 2015-10-02
@azazelpw

netstat -tnlp
if
127.0.0.1:5432
then you need to change the setting listen_addresses = 'localhost' to listen_addresses = '*' in
/var/lib/postgres/
postgresql.conf and restart postgres also look pg_hba.conf set host all all 0.0. 0.0/0 password password can be set like this psql -U postgres -c "ALTER USER postgres PASSWORD 'PASSWORD'"

K
krypt3r, 2015-10-02
@krypt3r

Check pg_hba.conf for available connections

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question