
dir ./
600 秒内至少有 1 个 key 被修改
后就执行快照
300 秒内至少有 10 个 key 被修改
后就执行快照
60 秒内至少有 10000 个 key 被修
改后就执行快照
stop-writes-on-bgsave-
error
备注:
1)stop-writes-on-bgsave-error,默认情况下,如果 Redis 最后一次存储失败后,Redis
就会自动停止写操作,这样可以提示到运维人员快照的写入结果,但是建议部署一些监控软
件或者脚本来观察写入情况
该问题的报错信息:
MISCONF Redis is configured to save RDB snapshots, but it is currently not
able to persist on disk. Commands that may modify the data set are disabled,
because this instance is configured to report errors during writes if RDB
snapshotting fails (stop-writes-on-bgsave-error option). Please check the
Redis logs for details about the RDB error.
2)dbfilename,生成的一种紧凑的二进制文件,文件很小有利于备份。文件有固定的
格式要求,它保存的是二进制数据,大体可以分为以下 5 部分:
• REDIS:文 件 头 保 存 的 是 长 为 5 个字节的 REDIS 字符,用于标识当前文件为 RDB
类型
文档被以下合辑收录
评论