psycopg2.OperationalError: could not connect to server: Connection refused
Is the server running on host "45.32.1XX.2XX" and accepting TCP/IP connections on port 5432?
Here,I've open my sockets.
tcp 0 0 127.0.0.1:5432 0.0.0.0:* LISTEN 11516/postgres
tcp6 0 0 ::1:5432 :::* LISTEN 11516/postgres
I googled that I should modify this pg_hba.conf
,but in my postgresql
root files, I didn't find this file at all.
Also I've succeed in connecting my another server.
Thanks.
Here,I've modified the pg_hba.conf
,updated thishost all all 218.3.A.B trust
and reloaded.But it didn't work either.