Barman server unable to connect to Primary

2.1k Views Asked by At

I have created and followed instructions from the barman documentation. I have a primary Postgres and backup barman servers. I am able to ssh to primary server from back server without password. But when running any of the barman commands like barman check Postgresdb-server I am unable to get any response. At same time the wal archiving is working fine as I see the wal logs in backup server. Even barman backup Postgresdb-server is not responding. Is there anything that I am missing? The log file says it is impossible to take backup but other than that there is no other message. I am using the latest barman 2.1 and PostgreSQL 9.6.2

[Postgresdb-server]
description =  "Example of PostgreSQL Database (via Ssh)"
ssh_command = ssh postgres@pg
conninfo = host=pg user=barman dbname=postgres
backup_method = rsync
reuse_backup = link
archiver = on

Update: The issue was resolved after opening a firewall port 5432 for external connections. In this case opening port 5432 from backup/barman server to primary postgres server. This helped resolved the issue.

psycopg2.connect("host=pg user=barman dbname=postgres") Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/usr/lib64/python2.7/site-packages/psycopg2/__init__.py", line 164, in connect conn = _connect(dsn, connection_factory=connection_factory, async=async) psycopg2.OperationalError: could not connect to server: Connection timed out Is the server running on host "pg" and accepting TCP/IP connections on port 5432?

0

There are 0 best solutions below