Unhandled promise rejection (rejection id: 764): ReplyError: MISCONF Redis is configured to save RDB

nodejs项目,redis报错完整内容:

Unhandled promise rejection (rejection id: 764): ReplyError: 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数据库是又爱又恨,经历过大量数据丢失,最近又一直报这个错误。

最后在网上找到了方法:

服务器是在linux下,

1、修改redis/redis.conf,搜索stop-writes-on-bgsave-error 把yes改为no;

2、修改 /etc/sysctl.cnf 文件,添加:vm.overcommit_memory=1

参考:

https://www.linuxidc.com/Linux/2012-07/66079.htm


意外金喜的博客:http://blog.csdn.net/zzwwjjdj1

发布了118 篇原创文章 · 获赞 232 · 访问量 153万+
展开阅读全文

没有更多推荐了,返回首页

©️2019 CSDN 皮肤主题: 编程工作室 设计师: CSDN官方博客

分享到微信朋友圈

×

扫一扫,手机浏览