I have pulled the docker image for Confluence and want to connect it to my PostgreSQL database.
I have followed this instruction for creating the user and database in PostgreSQL:
https://www.digitalocean.com/community/tutorials/how-to-install-and-use-postgresql-on-ubuntu-16-04
and from Atlassian:
https://confluence.atlassian.com/doc/database-setup-for-postgresql-173244522.html
But during the installation process of confluence there is an error:
Configuring database failed
org.postgresql.util.PSQLException: Connection to localhost:5432 refused. Check that the hostname and port are correct and that the postmaster is accepting TCP/IP connections.
In the setup field I just left the standard input:
DriverClassName: org.postgresql.Driver
DatabaseURL: jdbc:postgresql://localhost:5432/confluence
Username and Password
I have installed apt-get install libpostgresql-jdbc-java and got libpostgresql-jdbc-java (9.2-1002-1)
However, I can not fix this error. Could someone please give me a hint what else I could figure out.
ps -f -u postgres
ps -f -u postgres
UID PID PPID C STIME TTY TIME CMD
postgres 3718 1 0 14:09 ? 00:00:00 /usr/lib/postgresql/9.5/bin/postgres -D /var/lib/postgresql/9.5/main -c config_file=/etc/postg
postgres 3720 3718 0 14:09 ? 00:00:00 postgres: checkpointer process
postgres 3721 3718 0 14:09 ? 00:00:00 postgres: writer process
postgres 3722 3718 0 14:09 ? 00:00:00 postgres: wal writer process
postgres 3723 3718 0 14:09 ? 00:00:00 postgres: autovacuum launcher process
postgres 3724 3718 0 14:09 ? 00:00:00 postgres: stats collector process
sudo netstat -ltnp | grep postgres
tcp 0 0 127.0.0.1:5432 0.0.0.0:* LISTEN 3718/postgres
tcp6 0 0 ::1:5432 :::* LISTEN 3718/postgres
sudo lsof -n -u postgres |grep LISTEN
postgres 3718 postgres 6u IPv4 23608 0t0 TCP 127.0.0.1:postgresql (LISTEN)
postgres 3718 postgres 7u IPv6 23609 0t0 TCP [::1]:postgresql (LISTEN)