Dee*_*aya 1 postgresql postgresql-9.6 barman
我正在尝试将Barman配置为备份.当我这样做时,barman check replica我会继续:
Server replica:
WAL archive: FAILED (please make sure WAL shipping is setup)
PostgreSQL: OK
superuser: OK
wal_level: OK
directories: OK
retention policy settings: OK
backup maximum age: FAILED (interval provided: 1 day, latest backup age: No available backups)
compression settings: OK
failed backups: OK (there are 0 failed backups)
minimum redundancy requirements: FAILED (have 0 backups, expected at least 2)
ssh: OK (PostgreSQL server)
not in recovery: FAILED (cannot perform exclusive backup on a standby)
archive_mode: OK
archive_command: OK
continuous archiving: OK
archiver errors: OK
Run Code Online (Sandbox Code Playgroud)
我正在使用Postgresql 9.6和barman 2.1; 我不确定这个问题可能会有人帮忙吗?这是我的Barman服务器配置:
description = "Database backup"
conninfo = host=<db-ip> user=postgres dbname=db
backup_method = rsync
ssh_command = ssh postgres@<db-ip>
archiver = on
Run Code Online (Sandbox Code Playgroud)
barman check尝试通过声明存档中确实存在某些内容来确认存档是否已正确设置.但是,WAL段通常只有在填满后才会存档,如果您的服务器处于空闲状态,则永远不会发生这种情况.
为了解决这个问题,Barman提供了一个强制段切换的命令,等待已完成的WAL显示,然后立即将其存档:
barman switch-xlog --force --archive replica
Run Code Online (Sandbox Code Playgroud)