连接Redis后执行命令错误 MISCONF Redis is configured to save RDB snapshots

Posted zhouxinfei

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了连接Redis后执行命令错误 MISCONF Redis is configured to save RDB snapshots相关的知识,希望对你有一定的参考价值。

今天在redis中执行setrange name 1 chun 命令时报了如下错误提示:

(error) MISCONF Redis is configured to save RDB snapshots, but is currently not able to persist on disk. Commands that may modify the data set are disabled. Please check Redis logs for details about the error.

大意为:(错误)misconf redis被配置以保存数据库快照,但misconf redis目前不能在硬盘上持久化。用来修改数据集合的命令不能用,请使用日志的错误详细信息。

技术分享图片
 

这是由于强制停止redis快照,不能持久化引起的,运行info命令查看redis快照的状态,如下:

技术分享图片
 

解决方案如下:

连接redis后运行 config set stop-writes-on-bgsave-error no 命令

关闭配置项stop-writes-on-bgsave-error解决该问题。



以上是关于连接Redis后执行命令错误 MISCONF Redis is configured to save RDB snapshots的主要内容,如果未能解决你的问题,请参考以下文章

解决redis连接错误:MISCONF Redis is configured to save RDB snapshots, but it is currently not able to...

解决redis连接错误:MISCONF Redis is configured to save RDB snapshots, but it is currently not able to...(示例

MISCONF Redis 配置为保存 RDB 快照

连接redis报错MISCONF Redis is configured to save RDB s

(error) MISCONF Redis is configured to save RDB snapshots, but is currently

(error) MISCONF Redis is configured to save RDB snapshots, but is currently not able to persist on d