gpt4 book ai didi

postgresql - WAL 存档 : FAILED (please make sure WAL shipping is setup)

转载 作者:行者123 更新时间:2023-11-29 12:29:15 26 4
gpt4 key购买 nike

我正在尝试将 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

我正在使用 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

最佳答案

barman check 尝试通过断言存档中确实存在某些内容来确认存档设置是否正确。但是,WAL 段通常只有在填满后才会归档,如果您的服务器空闲,则永远不会发生这种情况。

为了解决这个问题,Barman 提供了一个强制段切换的命令,等待完成的 WAL 出现,然后立即将其归档:

barman switch-xlog --force --archive replica

关于postgresql - WAL 存档 : FAILED (please make sure WAL shipping is setup),我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/42595792/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com