apache ab post get 测试

其他技术

2017-12-16

39

0

技术:ab工具

运行环境:windows 10 + ab

demo功能:提供ab 测试命令demo

post

ab.exe -n 100000  -c 100 -p "a.json" -T "application/json" "http://XXXXXXX/Web/XXXXX/CloXXXXXudSearch"

10000: 总共请求数

100:并发数

-p: 需要post的文件

-T:这个你看看数据 就知道了

get

>ab.exe -c 10 -n 10 http://www.baidu.com/?gid=2

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 sys.51ruipin.com (be patient)
Completed 100 requests
Completed 200 requests
Completed 300 requests
Completed 400 requests
Completed 500 requests
Completed 600 requests
Completed 700 requests
Completed 800 requests
Completed 900 requests
Completed 1000 requests
Finished 1000 requests


Server Software: Microsoft-IIS/7.5
Server Hostname: sys.51ruipin.com
Server Port: 80

Document Path: Web/XXXXX/CloXXXXXudSearch
Document Length: 221 bytes

Concurrency Level: 100
Time taken for tests: 33.561 seconds-- 测试总共耗时多少秒
Complete requests: 1000- -总共完成多少个请求
Failed requests: 0
Write errors: 0
Non-2xx responses: 1000
Total transferred: 715000 bytes
Total POSTed: 628000
HTML transferred: 221000 bytes
Requests per second: 29.80 [#/sec] (mean) -- 每秒处理的请求数
Time per request: 3356.095 [ms] (mean)
Time per request: 33.561 [ms] (mean, across all concurrent requests)
Transfer rate: 20.81 [Kbytes/sec] received
18.27 kb/s sent
39.08 kb/s total



Percentage of the requests served within a certain time (ms)
50% 3372
66% 3404
75% 3437
80% 3448
90% 3481
95% 3520
98% 3563
99% 3573
100% 3584 (longest request) 

欢迎添加微信,互相学习↑↑↑ -_-

发表评论

全部评论:0条

白老虎

programming is not only to solve problems, ways to think