Ab 测试笔记

2019-05-29  本文已影响0人  chichoyi

请求命令

# -n 本次总请求次数
# -c 并发次数
ab -n 100 -c 10 api.com/kong

返回参数解析

This is ApacheBench, Version 2.3 <$Revision: 1826891 $>
Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
Licensed to The Apache Software Foundation, http://www.apache.org/

Benchmarking apiv3.com (be patient).....done


Server Software:        nginx/1.15.6  ##(服务器软件名称及版本信息)
Server Hostname:        apiv3.com  ##(服务器主机名)
Server Port:            80  ##(服务器端口)

Document Path:          /kong  ##(供测试的URL路径)
Document Length:        14 bytes  ##(供测试的URL返回的文档大小)

Concurrency Level:      10 ##(并发数)
Time taken for tests:   16.871 seconds ##(压力测试消耗的总时间)
Complete requests:      100  ##(压力测试总次数)
Failed requests:        0  ##(失败的请求数)
Total transferred:      27100 bytes  ##(传输的总数据量)
HTML transferred:       1400 bytes  ##(HTML文档的总数据量)
Requests per second:    5.93 [#/sec] (mean) ##(平均每秒的请求数)
Time per request:       1687.057 [ms] (mean)   ##(所有并发用户(这里是10)都请求一次的平均时间)
Time per request:       168.706 [ms] (mean, across all concurrent requests) ##(单个用户请求一次的平均时间)
Transfer rate:          1.57 [Kbytes/sec] received  ##(传输速率,单位:KB/s)

Connection Times (ms)
              min  mean[+/-sd] median   max
Connect:        0    0   0.1      0       0
Processing:   527 1580 281.9   1586    2406
Waiting:      525 1580 282.0   1586    2405
Total:        527 1580 281.8   1587    2406

Percentage of the requests served within a certain time (ms)
  50%   1587
  66%   1614
  75%   1654
  80%   1682
  90%   1778
  95%   2163
  98%   2363
  99%   2406
 100%   2406 (longest request)
上一篇 下一篇

猜你喜欢

热点阅读