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)

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章