Postgresql with nodered - Error: connect ECONNREFUSED

I am trying to connect PostgreSQL with nodered, but:
Error: connect ECONNREFUSED

Nodered is inside a virtual machine (ip:

PostgreSQL isinside virtual machine (

Between the virtual machines the communication is correct, since I can ping without problem

What is happening?


Have you etup PostgreSQL to allow Remote Connections?

Tons of info on the net e.g. "How To Configure PostgreSQL to Allow Remote Connections – TecAdmin" How To Configure PostgreSQL to Allow Remote Connections – TecAdmin

Also check (from the node-red machine) that port 5432 is open on the db machine. Using nmap for example.

Thanks! I have follow link steps. In the first time i had a problem because i couldn´t login in pgadmin after the pg_hba.conf file change. After i saw a comment thas says: use "host all all ::0/0 md5" and not "host all all :/0 md5" and the connection was ok! Thanks!

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.