网站性能测试工具ab(Apache Bench)
进入ab.exe根目录
ab-n1000-c10http://www.baidu.com/
ab-n1000-c10http://www.baidu.com/index.php
相关参数
-n:请求数
-c:并发数
可以测试的参数
Timetakenfortests:测试用时
Requestspersecond:每秒请求数
测试用时*每秒请求数=1000
[root@developbin]#ab-n1000-c20www.baidu.com/
ThisisApacheBench,Version2.0.40-dev<$Revision:1.146$>apache-2.0
Copyright1996AdamTwiss,ZeusTechnologyLtd,http://www.zeustech.net/
Copyright1997-2005TheApacheSoftwareFoundation,http://www.apache.org/
Benchmarkingwww.baidu.com(bepatient)
Completed100requests
Completed200requests
Completed300requests
Completed400requests
Completed500requests
Completed600requests
Completed700requests
Completed800requests
Completed900requests
Finished1000requests
ServerSoftware:BWS/1.0
ServerHostname:www.baidu.com
ServerPort:80
DocumentPath:/
DocumentLength:3723bytes
ConcurrencyLevel:20
//测试用时
Timetakenfortests:121.445016seconds
Completerequests:1000
Failedrequests:162
(Connect:0,Length:150,Exceptions:12)
Writeerrors:0
Totaltransferred:3422950bytes
HTMLtransferred:3164550bytes
//每秒请求数
Requestspersecond:8.23[#/sec](mean)
Timeperrequest:2428.900[ms](mean)
//每请求数耗时
Timeperrequest:121.445[ms](mean,acrossallconcurrentrequests)
Transferrate:27.52[Kbytes/sec]received
ConnectionTimes(ms)
minmean[+/-sd]medianmax
Connect:138103549.22045020
Processing:11366593.31258362
Waiting:037107.1191999
Total:2711773528.232545049
Percentageoftherequestsservedwithinacertaintime(ms)
50%325
66%568
75%794
80%971
90%3030
95%3068
98%9054
99%21047
100%45049(longestrequest)
相关推荐
万物皆可测量,这条定律同样适用于我们经常打交道的各种服务器和应用系统。服务器选型、测试、优化都是一些长期复杂的工作,如何在TurboCMS的项目中快速满足客户需求,我们只需要掌握以下的一些知识要点即可