BGSAVE报错。 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. redis在写入过程出现这个报错一般是因为redis做了持久化但是持久化失败所以无法写入,一般都是dump.rdb文件没有权限或者内存不够导致的, BGSAVE 会 fork 出一个子进程,会占用两倍的内存。
解决方法 config set stop-writes-on-bgsave-error no 用上面命令把持久化报错关掉,redis可恢复写的操作。不过这只是忽略了错误,rdb持久化仍然会错误,导致rdb备份失效,解决办法还是要保证服务器的内存要大于redis使用内存的2倍。