今天在程序中,jedis put数据到redis过程中,“MISCONF Redis is configured to save RDB snapshots, but is currently not able to persist on disk”报错;

再查看Redis日志,看到有这样的错误提示“Can’t save in background: fork: Cannot allocate memory”,这个提示很明显"Fork进程时内存不够用了!",但内存明明还有一个多G;

经网上查询,Redis在保存数据到硬盘时为了避免主进程假死,需要Fork一份主进程,然后在Fork进程内完成数据保存到硬盘的操作,如果主进程使用了4GB的内存,Fork子进程的时候需要额外的4GB,此时内存就不够了,Fork失败,进而数据保存硬盘也失败了。

解决如下:

执行命令 sysctl vm.overcommit_memory=1

/etc/sysctl.conf 文件添加

vm.overcommit_memory=1

Redis "MISCONF Redis is configured to save RDB snapshots, but is currently not able to persist on disk"问题的更多相关文章

  1. Redis "MISCONF Redis is configured to save RDB snapshots, but is currently not able to persist on disk"问题的解决

    异常详细信息 Exception in thread "main" redis.clients.jedis.exceptions.JedisDataException: MISCO ...

  2. Redis "MISCONF Redis is configured to save RDB snapshots, but is currently not able to persist on disk"问题的解决(转)

    今天第二次遇到Redis “MISCONF Redis is configured to save RDB snapshots, but is currently not able to persis ...

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

    今天运行Redis时发生错误,错误信息如下: (error) MISCONF Redis is configured to save RDB snapshots, but is currently n ...

  4. (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 t

    运行redis过程中,突然报错如下: (error) MISCONF Redis is configured to save RDB snapshots, but is currently not a ...

  5. redis 不能持久化问题 MISCONF Redis is configured to save RDB snapshots, but is currently not able to persist on disk.

    转载自:http://www.cnblogs.com/anny-1980/p/4582674.html kombu.exceptions.OperationalError: MISCONF Redis ...

  6. 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报错了,重启了一下好了,一会又报错了. 错误信息: MISCONF Redis is configured to save RDB snapshots, but ...

  7. redis 异常 MISCONF Redis is configured to save RDB snapshots, but is currently not able to persist on disk

    MISCONF Redis is configured to save RDB snapshots, but is currently not able to persist on disk. 解决方 ...

  8. redis 出现(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

    如果在ubuntu安装的redis含端口使用,但是某些时候常常出现 (error) MISCONF Redis is configured to save RDB snapshots, but is ...

  9. redis异常:(error) MISCONF Redis is configured to save RDB snapshots, but is currently not able to persist on disk.

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

随机推荐

  1. STL源码剖析(算法)

    STL中算法是基于迭代器来实现的. 有了容器中迭代器的实现(对operator*.operator++等的重载),STL中大部分算法实现就显得很简单了. 先看一例关于find算法的实现: templa ...

  2. Java提高合集(转载)

    转载自:http://www.cnblogs.com/pony1223/p/7643842.html Java提高十五:容器元素比较Comparable&Comparator深入分析 JAVA ...

  3. hiberbnate 缓存策略概述

    1. 首先了解什么是缓存 这里说的缓存并不是指计算机的内存或者CPU的一二级缓存. 缓存是指为了降低应用程序对物理数据源访问的频次,从而提高应用程序的运行性能的一种策略.即对物理数据源的复制,存在于内 ...

  4. LaTex幻灯片制作

    头部声明是“幻灯片”: \documentclass{beamer} 其他: \documentclass{beamer}\usepackage{graphicx}\usepackage{epstop ...

  5. hadoop2.7.0实践- WordCount

    环境要求 说明:本文档为wordcount的mapreduce job编写及执行文档. 操作系统:Ubuntu14 x64位 Hadoop:Hadoop 2.7.0 Hadoop官网:http://h ...

  6. Scroller应用:ListView滑动删除

    1.设计思路 在Scroller的应用--滑屏实现中使用Scroller实现滑屏效果,这里使用Scroller与ListView实现相似QQ滑动.然后点击删除功能.设计思路是Item使用Scrolle ...

  7. Python 统计代码的行数,Python脚本 统计代码

    # coding=utf-8 import os import time # 需要统计的文件夹或者文件,这是在windows下运行的,如果使用Linux系统可以使用 basedir = '/app/l ...

  8. C++语言基础(21)-异常

    C++语言本身或者标准库抛出的异常都是 exception 的子类,称为标准异常(Standard Exception).你可以通过下面的语句来捕获所有的标准异常: try{ //可能抛出异常的语句 ...

  9. Apache: You don't have permission to access / on this server

    当我们需要使用Apache配置虚拟主机时,有可能会出现这个问题:Apache: You don't have permission to access / on this server # 同IP不同 ...

  10. Spring可扩展的XML Schema机制

    可扩展的XML Schema机制 从Spring2.0开始,Spring提供了XML Schema可扩展机制,用户可以自定义XML Schema文件,并自定义XML Bean解析器,并集成到Sprin ...