• redis-benchmark使用说明


    Redis-benchmark为Redis性能测试工具。

    指令说明:

    Usage: redis-benchmark [-h <host>] [-p <port>] [-c <clients>] [-n <requests]> [-k <boolean>]
     
    -h <hostname>      Server hostname (default 127.0.0.1)
    -p <port>          Server port (default 6379)
    -s <socket>        Server socket (overrides host and port)
    -c <clients>       Number of parallel connections (default 50)
    -n <requests>      Total number of requests (default 10000)
    -d <size>          Data size of SET/GET value in bytes (default 2)
    -k <boolean>       1=keep alive 0=reconnect (default 1)
    -r <keyspacelen>   Use random keys for SET/GET/INCR, random values for SADD
      Using this option the benchmark will get/set keys
      in the form mykey_rand:000000012456 instead of constant
      keys, the <keyspacelen> argument determines the max
      number of values for the random number. For instance
      if set to 10 only rand:000000000000 - rand:000000000009
      range will be allowed.
    -P <numreq>        Pipeline <numreq> requests. Default 1 (no pipeline).
    -q                 Quiet. Just show query/sec values 只显示每秒钟能处理多少请求数结果
    --csv              Output in CSV format
    -l                 Loop. Run the tests forever 永久测试
    -t <tests>         Only run the comma separated list of tests. The test
                        names are the same as the ones produced as output.
    -I                 Idle mode. Just open N idle connections and wait.  

    实例:

    redis-benchmark -h 127.0.0.1 -p 6379 -q -d 100  
    SET/GET 100 bytes 检测host为127.0.0.1 端口为6379的redis服务器性能

    E:Codegithub
    edis-configinwindows (master -> origin)
    λ redis-benchmark -h 127.0.0.1 -p 6380 -n 10000 -q
    PING_INLINE: 71428.57 requests per second
    PING_BULK: 79365.08 requests per second
    SET: 72992.70 requests per second
    GET: 59880.24 requests per second
    INCR: 74074.07 requests per second
    LPUSH: 71428.57 requests per second
    LPOP: 75187.97 requests per second
    SADD: 72463.77 requests per second
    SPOP: 75187.97 requests per second
    LPUSH (needed to benchmark LRANGE): 71428.57 requests per second
    LRANGE_100 (first 100 elements): 28011.21 requests per second
    LRANGE_300 (first 300 elements): 14245.01 requests per second
    LRANGE_500 (first 450 elements): 10593.22 requests per second
    LRANGE_600 (first 600 elements): 8431.70 requests per second
    MSET (10 keys): 52083.33 requests per second
    

      

  • 相关阅读:
    ADO.NET 2.调用存储过程
    Resharper上手指南
    获取HTML源码(只取文字,判断编码,过滤标签)
    .net(c#) winform文本框只能输入数字,不能其他非法字符(转)
    ADO.NET – 3.书籍管理系统详解
    GemBox.ExcelLite.dll导出到Excel
    C#4.0图解教程 第7章 类和继承
    C#读取网站HTML内容
    C#回顾 – 1.IO文件操作
    Javascript s10 (Jquery相关手册整合及功能实现)
  • 原文地址:https://www.cnblogs.com/Martianhh/p/9965183.html
Copyright © 2020-2023  润新知