zoukankan      html  css  js  c++  java
  • Redis Info详解

    info
    # Server
    redis_version:3.0.7  redis_version: Redis 服务器版本
    redis_git_sha1:00000000  redis_git_sha1: Git SHA1
    redis_git_dirty:0  redis_git_dirty: Git dirty flag
    redis_build_id:4022fe7523cdeee3 
    redis_mode:standalone  redis_mode:单机or集群
    os:Linux 2.6.32-358.el6.x86_64 x86_64  os: Redis 服务器的宿主操作系统
    arch_bits:64  arch_bits: 架构(32 或 64 位)
    multiplexing_api:epoll  multiplexing_api: Redis 所使用的事件处理机制
    gcc_version:4.4.7  gcc_version: 编译 Redis 时所使用的 GCC 版本
    process_id:6206 process_id: 服务器进程的 PID
    run_id:4632606198da81ebf80b7e29a352bd58f9d3a6f1  run_id: Redis 服务器的随机标识符(用于 Sentinel 和集群)
    tcp_port:6379  tcp_port: TCP/IP 监听端口
    uptime_in_seconds:199  uptime_in_seconds: 自 Redis 服务器启动以来,经过的秒数
    uptime_in_days:0  uptime_in_days: 自 Redis 服务器启动以来,经过的天数
    hz:10
    lru_clock:10160707   lru_clock: 以分钟为单位进行自增的时钟,用于 LRU 管理
    config_file:/data/redis/redis6379/redis6379.conf  config_file:redis配置文件

    # Clients
    connected_clients:2  connected_clients: 已连接客户端的数量(不包括通过从属服务器连接的客户端)
    client_longest_output_list:0  client_longest_output_list: 当前连接的客户端当中,最长的输出列表
    client_biggest_input_buf:0  client_biggest_input_buf: 当前连接的客户端当中,最大输入缓存
    blocked_clients:0  blocked_clients: 正在等待阻塞命令(BLPOP、BRPOP、BRPOPLPUSH)的客户端的数量

    # Memory
    used_memory:1908784   used_memory: 由 Redis 分配器分配的内存总量,以字节(byte)为单位
    used_memory_human:1.82M   used_memory_human: 以人类可读的格式返回 Redis 分配的内存总量
    used_memory_rss:2289664   used_memory_rss: 从操作系统的角度,返回 Redis 已分配的内存总量(俗称常驻集大小)。这个值和 top 、 ps 等命令的输出一致。
    used_memory_peak:1923848   used_memory_peak: Redis 的内存消耗峰值(以字节为单位)
    used_memory_peak_human:1.83M   used_memory_peak_human: 以人类可读的格式返回 Redis 的内存消耗峰值
    used_memory_lua:36864   used_memory_lua: Lua 引擎所使用的内存大小(以字节为单位)
    mem_fragmentation_ratio:1.20   mem_fragmentation_ratio: used_memory_rss 和 used_memory 之间的比率
    mem_allocator:jemalloc-3.6.0   mem_allocator: 在编译时指定的, Redis 所使用的内存分配器。可以是 libc 、 jemalloc 或者 tcmalloc 。
    在理想情况下, used_memory_rss 的值应该只比 used_memory 稍微高一点儿。
    当 rss > used ,且两者的值相差较大时,表示存在(内部或外部的)内存碎片。
    内存碎片的比率可以通过 mem_fragmentation_ratio 的值看出。
    当 used > rss 时,表示 Redis 的部分内存被操作系统换出到交换空间了,在这种情况下,操作可能会产生明显的延迟。
    当 Redis 释放内存时,分配器可能会,也可能不会,将内存返还给操作系统。
    如果 Redis 释放了内存,却没有将内存返还给操作系统,那么 used_memory 的值可能和操作系统显示的 Redis 内存占用并不一致。
    查看 used_memory_peak 的值可以验证这种情况是否发生。

    # Persistence
    loading:0   loading:是否正在 load of a dump file 的标记
    rdb_changes_since_last_save:0   rdb_changes_since_last_save:自从上次save后rdb change的数量
    rdb_bgsave_in_progress:0   rdb_bgsave_in_progress:是否正常进行bgsave
    rdb_last_save_time:1469778323   rdb_last_save_time:上次save的unix时间戳
    rdb_last_bgsave_status:ok   rdb_last_bgsave_status:rdb上次bgsave的状态
    rdb_last_bgsave_time_sec:0   rdb_last_bgsave_time_sec:上次bgsave的持续时间(s)
    rdb_current_bgsave_time_sec:-1   rdb_current_bgsave_time_sec:正在bgsave的持续时间(s)
    aof_enabled:1   aof_enabled:启用AOF
    aof_rewrite_in_progress:0   aof_rewrite_in_progress:AOF rewrite operation是否正在进行
    aof_rewrite_scheduled:0   aof_rewrite_scheduled:Flag indicating an AOF rewrite operation will be scheduled once the on-going RDB save is complete.
    aof_last_rewrite_time_sec:-1  aof_last_rewrite_time_sec:上次AOF rewrite持续时间
    aof_current_rewrite_time_sec:-1   aof_current_rewrite_time_sec:正在进行的AOF rewrite持续时间
    aof_last_bgrewrite_status:ok   aof_last_bgrewrite_status:上次AOF rewrite状态
    aof_last_write_status:ok
    aof_current_size:1021   aof_current_size:AOF当前大小
    aof_base_size:1021   aof_base_size:AOF file size on latest startup or rewrite
    aof_pending_rewrite:0   aof_pending_rewrite: Flag indicating an AOF rewrite operation will be scheduled once the on-going RDB save is complete.
    aof_buffer_length:0   aof_buffer_length: Size of the AOF buffer
    aof_rewrite_buffer_length:0      aof_rewrite_buffer_length: Size of the AOF rewrite buffer
    aof_pending_bio_fsync:0   aof_pending_bio_fsync: Number of fsync pending jobs in background I/O queue
    aof_delayed_fsync:0    aof_delayed_fsync: Delayed fsync counter

    If a load operation is on-going, these additional fields will be added:
    loading_start_time: Epoch-based timestamp of the start of the load operation
    loading_total_bytes: Total file size
    loading_loaded_bytes: Number of bytes already loaded
    loading_loaded_perc: Same value expressed as a percentage
    loading_eta_seconds: ETA in seconds for the load to be complete

    # Stats
    total_connections_received:5   total_connections_received: Total number of connections accepted by the server
    total_commands_processed:192   total_commands_processed: Total number of commands processed by the server
    instantaneous_ops_per_sec:1   instantaneous_ops_per_sec: Number of commands processed per second
    total_net_input_bytes:6662  
    total_net_output_bytes:7005
    instantaneous_input_kbps:0.04
    instantaneous_output_kbps:0.00
    rejected_connections:0   rejected_connections: Number of connections rejected because of maxclients limit
    sync_full:1
    sync_partial_ok:0
    sync_partial_err:0
    expired_keys:0   expired_keys: Total number of key expiration events
    evicted_keys:0   evicted_keys: Number of evicted keys due to maxmemory limit
    keyspace_hits:0   keyspace_hits: Number of successful lookup of keys in the main dictionary
    keyspace_misses:0   keyspace_misses: Number of failed lookup of keys in the main dictionary
    pubsub_channels:0   pubsub_channels: Global number of pub/sub channels with client subscriptions
    pubsub_patterns:0   pubsub_patterns: Global number of pub/sub pattern with client subscriptions
    latest_fork_usec:141   latest_fork_usec: Duration of the latest fork operation in microseconds
    migrate_cached_sockets:0

    # Replication
    role:master  
    connected_slaves:1
    slave0:ip=192.168.56.159,port=6380,state=online,offset=239,lag=0
    master_repl_offset:239
    repl_backlog_active:1
    repl_backlog_size:1048576
    repl_backlog_first_byte_offset:2
    repl_backlog_histlen:238

    If the instance is a slave, these additional fields are provided:
    master_host: Host or IP address of the master
    master_port: Master listening TCP port
    master_link_status: Status of the link (up/down)
    master_last_io_seconds_ago: Number of seconds since the last interaction with master
    master_sync_in_progress: Indicate the master is syncing to the slave
    If a SYNC operation is on-going, these additional fields are provided:
    master_sync_left_bytes: Number of bytes left before syncing is complete
    master_sync_last_io_seconds_ago: Number of seconds since last transfer I/O during a SYNC operation
    If the link between master and slave is down, an additional field is provided:
    master_link_down_since_seconds: Number of seconds since the link is down

    # CPU
    used_cpu_sys:0.04   used_cpu_sys: System CPU consumed by the Redis server
    used_cpu_user:0.16   used_cpu_user:User CPU consumed by the Redis server
    used_cpu_sys_children:0.00   used_cpu_sys_children: System CPU consumed by the background processes
    used_cpu_user_children:0.00   used_cpu_user_children: User CPU consumed by the background processes

    # Cluster
    cluster_enabled:0

    # Keyspace
    db0:keys=19,expires=0,avg_ttl=0
    db1:keys=2,expires=0,avg_ttl=0
    db2:keys=1,expires=0,avg_ttl=0

  • 相关阅读:
    APP端自动化 之 Windows-Android-Appium环境搭建
    Python3学习笔记-继承、封装、多态
    Python3学习笔记-构造函数与析构函数
    多线程同时操作界面使用互斥体
    AX2009 C#客户端通过Web service批量审核工作流(一)
    AX2009报表发送邮件(二)
    AX2009报表发送邮件(一)
    AX2012分页显示数据
    AX2012 菜单根据不同公司动态显示
    AX2012使用域用户组
  • 原文地址:https://www.cnblogs.com/miaosj/p/10288716.html
Copyright © 2011-2022 走看看