Mac故障排查系列:redis删除key报错MISCONF Redis is configured to save RDB snapshots, but it's currently unable to persist to disk.

发布时间 2023-09-26 15:07:34作者: jamstack

背景:Mac下使用Another Redis Desktop Manager客户端,删除key,遇到报错:MISCONF Redis is configured to save RDB snapshots, but it's currently unable to persist to 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是通过docker安装的,还是brew安装的,或者是使用shell安装的,怎么办呢?

我们可以这样做:

# 通过6379端口得到redis的pid,本案例中的pid为1835,请以你的实际案例为准
lsof -i:6379

# 根据pid就可以得到redis的路径
ps -ef | grep 1835