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.
配置優化,添加以下配置項到/etc/sysctl.conf
配置文件:
vm.overcommit_memory = 1
執行以下命令使其實時生效:
sysctl vm.overcommit_memory=1
如果Redis緩存的為非重要數據,如網頁緩存,對可用性要求不高,可以修改Redis的配置文件如下:
stop-writes-on-bgsave-error no
如果緩存數據丟失也可以接受,可以關閉appendonly
:
appendonly no
Stackoverflow:https://stackoverflow.com/questions/19581059/misconf-redis-is-configured-to-save-rdb-snapshots
Redis Persistence:https://redis.io/topics/persistence