I am trying to get streaming backups going.
As I couldn't figure out yet how to address a secondary recovery server (which I assume to be the recomemnded method) I try to recover a barman backup on the main server where I run into rsync errors.
barman@vm-51150-0188:~> barman recover vm-51150-0196 20211228T144114 /opt/db/data/postgres/data
Starting local restore for server vm-51150-0196 using backup 20211228T144114
Destination directory: /opt/db/data/postgres/data
Copying the base backup.
ERROR: Failure copying base backup: data transfer failure
rsync error:
rsync: change_dir#1 "/opt/db/data/postgres/data" failed: Permission denied (13)
rsync error: errors selecting input/output files, dirs (code 3) at main.c(621) [Receiver=3.1.3]
my surpise that rsync is involved at all with backup-method postgres aside ... I can't make much sense of this
- there is a user barman on that server.
- the permissions on the PGDATA directory are quite permissive (0760 with barman user being a member of the postgres group)
- I can rsync random files as barman user from the barman server into the PGDATA folder