AB压力测试httpd服务器性能

 

AB压力测试httpd服务器性能
[root@mail conf]# ulimit -a | grep "open files"
open files                      (-n) 1024
[root@mail conf]# ulimit -n 10000
[root@mail conf]# ulimit -a | grep "open files"
open files                      (-n) 10000

[root@mail conf]# /usr/local/http/bin/ab -c 2000 -n 4000 http://www.test1.com/
This is ApacheBench, Version 2.3 <$Revision: 655654 $>
Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
Licensed to The Apache Software Foundation, http://www.apache.org/

Benchmarking www.test1.com (be patient)
Completed 400 requests
Completed 800 requests
Completed 1200 requests
Completed 1600 requests
Completed 2000 requests
Completed 2400 requests
Completed 2800 requests
Completed 3200 requests
Completed 3600 requests
Completed 4000 requests
Finished 4000 requests


Server Software:        Apache/2.2.15
Server Hostname:        www.test1.com
Server Port:            80

Document Path:          /
Document Length:        14 bytes

Concurrency Level:      2000                       //用于并发连接测试的请求数
Time taken for tests:   4.974 seconds              //测试过程耗损的时间
Complete requests:      4000                       //测试过程中总共完成的请求数
Failed requests:        0                          //失败的请求数
Write errors:           0
Total transferred:      1264316 bytes              //测试过程的网络传输量
HTML transferred:       56014 bytes                //测试过程中的HTML内容传输量
Requests per second:    804.18 [#/sec] (mean)      //服务器平均每秒响应的请求数
Time per request:       2487.002 [ms] (mean)       //服务器平均每请求的响应时间
Time per request:       1.244 [ms] (mean, across all concurrent requests)
Transfer rate:          248.23 [Kbytes/sec] received

Connection Times (ms)                   //连接时间统计信息
              min  mean[+/-sd] median   max
Connect:        0  642 1074.5      1    4245
Processing:     0  421 688.1     45    3078
Waiting:        0  420 688.2     44    3078
Total:         32 1062 1384.0     52    4247

Percentage of the requests served within a certain time (ms)
  50%     52
  66%   1500
  75%   2204
  80%   2409
  90%   3314
  95%   4048
  98%   4150
  99%   4245
 100%   4247 (longest request)

 

本文出自 “dsafsa_技术博客” 博客,谢绝转载!

你可能感兴趣的:(性能,ab压力测试,httpd服务器)