使用redis进行set值时出现如下问题:
127.0.0.1:6379> set a 1
(error) 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.
redis快照被强制关闭了导致不能持久化的问题,可通过修改stop-writes-on-bgsave-error的值来解决此问题。
127.0.0.1:6379> config set stop-writes-on-bgsave-error no
OK
127.0.0.1:6379> set a 1
OK
本文介绍了解决Redis因快照失败而无法写入数据的问题。通过调整配置项stop-writes-on-bgsave-error,使Redis在快照失败时仍能进行数据写入操作。
1万+

被折叠的 条评论
为什么被折叠?



