Redis Bgrewriteaof 命令
Redis 教程
· 2019-03-08 13:12:14
Redis Bgrewriteaof 命令用于异步执行一个 AOF(AppendOnly File) 文件重写操作。重写会创建一个当前 AOF 文件的体积优化版本。
即使 Bgrewriteaof 执行失败,也不会有任何数据丢失,因为旧的 AOF 文件在 Bgrewriteaof 成功之前不会被修改。
注意:从 Redis 2.4 开始, AOF 重写由 Redis 自行触发, BGREWRITEAOF 仅仅用于手动触发重写操作。
语法
redis Bgrewriteaof 命令基本语法如下:
redis 127.0.0.1:6379> BGREWRITEAOF
可用版本
>= 1.0.0
返回值
反馈信息。
实例
redis 127.0.0.1:6379> Background append only file rewriting started
点击查看所有 Redis 教程 文章: https://codercto.com/courses/l/33.html
Fluent Python
Luciano Ramalho / O'Reilly Media / 2015-8-20 / USD 39.99
Learn how to write idiomatic, effective Python code by leveraging its best features. Python's simplicity quickly lets you become productive with it, but this often means you aren’t using everything th......一起来看看 《Fluent Python》 这本书的介绍吧!