|
大家有没有用过apache自带的性能测试工具ab?我怎么用它测试,产生2个并发连接,就会出现失败请求数呢?请教各位高手,谢谢!配置文件里未设置并发连接数。
ab -n 100 -c 2 http://localhost/index.php,结果:
Concurrency Level: 2
Time taken for tests: 1.187 seconds
Complete requests: 100
Failed requests: 18
(Connect: 0, Receive: 0, Length: 18, Exceptions: 0)
Write errors: 0
Total transferred: 1784104 bytes
HTML transferred: 1752404 bytes
Requests per second: 84.23 [#/sec] (mean)
Time per request: 23.745 [ms] (mean)
Time per request: 11.873 [ms] (mean, across all concurrent requests)
Transfer rate: 1467.48 [Kbytes/sec] received
Connection Times (ms)
min mean[+/-sd] median max
Connect: 0 0 1.4 0 14
Processing: 16 23 5.5 22 43
Waiting: 16 23 5.2 22 43
Total: 16 24 5.6 22 43
Percentage of the requests served within a certain time (ms)
50% 22
66% 24
75% 27
80% 29
90% 31
95% 36
98% 40
99% 43
100% 43 (longest request) |
|