The default configuration after installing PostgreSQL 9.4 only allows localhost tcp connections, or using Unix domain sockets. This isn't sufficient when setting up a database server separate from the app server.
- Open
/etc/postgresql/9.4/main/postgresql.conf
and look for thelisten_addresses
setting. The default islocalhost
. Change it to*
.