一文带你深入了解Redis的持久化方式及其原理

作者:域名 来源:域名 浏览: 【】 发布时间:2025-11-05 11:18:54 评论数:
一文带你深入了解Redis的持久化方式及其原理
复制################################ SNAPSHOTTING  ################################  #  # Save the DB on disk:  #  #   save <seconds> <changes>  #  #   Will save the DB if both the given number of seconds and the given  #   number of write operations against the DB occurred.  #  #   In the example below the behaviour will be to save:  #   after 900 sec (15 min) if at least 1 key changed  #   after 300 sec (5 min) if at least 10 keys changed  #   after 60 sec if at least 10000 keys changed  #   save "" # 自动生成快照的文带触发机制 中间的是时间,单位秒,深入后面的企商汇解R久化及是变更数据 60 秒变更 10000 条数据则自动生成快照  save 900 1  save 300 10  save 60 10000  # 生成快照失败时,主线程是原理否停止写入  stop-writes-on-bgsave-error yes  # 是否采用压缩算法存储  rdbcompression yes  # 数据恢复时是免费信息发布网否检测 RDB文件有效性  rdbchecksum yes  # The filename whereto dump the DB  # RDB 快照生成的文件名称  dbfilename dump.rdb  # 快照生成的路径 AOF 也是存放在这个路径下面  dir .  1.2.3.4.5.6.7.8.9.10.11.12.13.14.15.16.17.18.19.20.21.22.23.24.25.26.27.28.29.30.31.32.33.34.

最近更新

点击排行