Redis CONFIG RESETSTAT命令

Redis CONFIG RESETSTAT命令教程

Redis 的 CONFIG RESETSTAT 命令用于重置 INFO 命令中的某些统计数据。

Redis CONFIG RESETSTAT命令重置配置列表

配置 描述
Keyspace hits 键空间命中次数
Keyspace misses 键空间不命中次数
Number of commands processed 执行命令的次数
Number of connections received 连接服务器的次数
Number of expired keys 过期key的数量
Number of rejected connections 被拒绝的连接数量
Latest fork(2) time 最后执行 fork(2) 的时间
The aof_delayed_fsync counter aof_delayed_fsync 计数器的值

Redis CONFIG RESETSTAT命令详解

语法

192.168.98.70:6379> CONFIG RESETSTAT

返回值

总是返回 OK 。

时间复杂度

O(1)

可用版本

>= 2.0.0

案例

CONFIG RESETSTAT重置配置

使用 CONFIG RESETSTAT 重置 Redis 配置

127.0.0.1:6379> CONFIG RESETSTAT OK

直接使用 CONFIG RESETSTAT 命令即可重置配置。

Redis CONFIG RESETSTAT命令总结

Redis 的 CONFIG RESETSTAT 命令用于重置 INFO 命令中的某些统计数据。