1、简要说明

Apache Bench 是Apache的网站性能测试小程序,Windows平台下的程序名简称ab.exe,要想获得这个80k的可执行程序,用户需要下载整个Apache Httpd软件包!还需要将其安装到电脑上,确实比较麻烦。

Webbench也是一款网站性能测试小程序,可以获得网站的吞吐率、传送速度等基本性能指标。该程序是在Linux下编程的,在Linux下编译安装使用都很方便,但在Windows 下的程序却没有。

为了方便起见,我将ab.exe 小程序单独拷贝出来,并且下载了webbench的源码,使用CodeBlocks程序和Cygwin64,将源码编译了一下,生成Windows7 环境下可执行的文件webbench.exe ,方便在一个平台下同时使用2个程序,进行网站性能测试。

2、下载地址

Windows7 64位下的两个网站性能测试小工具下载地址:

链接:https://pan.baidu.com/s/1hDhBlNc4ss_sp-qPYk_kEQ

提取码:upas

3、运行截图:

01-Windows7 64位下webbench测试结果

02-Apache Bench 性能测试小工具-运行参数

03-Apache Bench 性能测试小工具-测试结果1

04-Apache Bench 性能测试小工具-测试结果2

4、测试命令及结果分析

ab.exe -n 15000 -c 100 http://www.abc.com/

# -n 15000总共发送的1.5万个访问请求N个

# -c 100模拟100个用户同时访问C个;

# 结果分析:

#   Concurrency Level:  模拟并发用户数(命令行中输入的数据)C个

#   Time taken for tests: 完成整个测试的时间T秒

#   Requests per second: 服务器性能(在当前并发下每秒能处理的请求数)=N/T个

#   Time per request: (mean)从用户的角度计算,每个请求平均花费时间=T/(N/C)
#       解释:每个用户发送N/C个请求,共花费T秒,每个请求平均花费时间=T/(N/C)

#   Time per request:(mean, across all concurrent requests)从服务器角度计算,完成每个请求的平均花费时间=T/N

#   Transfer rate: 传送速率

webbench.exe -c 100 -t 5 http://www.abc.com/

# -c 100模拟100个用户同时访问;

# -t 5 持续5秒钟测试时间

# 需要测试的网址 http://www.abc.com/ ,注意只测网站名时,结尾要加/

#

# Speed pages/min 每分钟多少个请求, Speed pages/sec 每秒钟多少个请求

# bytes/sec  传送速率

# Requests: 总共完成的请求数

5、注意事项

!!!不要对公共网址发送大量访问请求!!!可用于自己的网站上线前的性能测试。

6、使用帮助

C:\>ab --help

ab: wrong number of arguments

Usage: ab [options] [http://]hostname[:port]/path

Options are:

-n requests     Number of requests to perform

-c concurrency  Number of multiple requests to make at a time

-t timelimit    Seconds to max. to spend on benchmarking

This implies -n 50000

-s timeout      Seconds to max. wait for each response

Default is 30 seconds

-b windowsize   Size of TCP send/receive buffer, in bytes

-B address      Address to bind to when making outgoing connections

-p postfile     File containing data to POST. Remember also to set -T

-u putfile      File containing data to PUT. Remember also to set -T

-T content-type Content-type header to use for POST/PUT data, eg.

'application/x-www-form-urlencoded'

Default is 'text/plain'

-v verbosity    How much troubleshooting info to print

-w              Print out results in HTML tables

-i              Use HEAD instead of GET

-x attributes   String to insert as table attributes

-y attributes   String to insert as tr attributes

-z attributes   String to insert as td or th attributes

-C attribute    Add cookie, eg. 'Apache=1234'. (repeatable)

-H attribute    Add Arbitrary header line, eg. 'Accept-Encoding: gzip'

Inserted after all normal header lines. (repeatable)

-A attribute    Add Basic WWW Authentication, the attributes

are a colon separated username and password.

-P attribute    Add Basic Proxy Authentication, the attributes

are a colon separated username and password.

-X proxy:port   Proxyserver and port number to use

-V              Print version number and exit

-k              Use HTTP KeepAlive feature

-d              Do not show percentiles served table.

-S              Do not show confidence estimators and warnings.

-q              Do not show progress when doing more than 150 requests

-l              Accept variable document length (use this for dynamic pages)

-g filename     Output collected data to gnuplot format file.

-e filename     Output CSV file with percentages served

-r              Don't exit on socket receive errors.

-m method       Method name

-h              Display usage information (this message)

C:\>webbench --help

webbench [option]... URL

-f|--force               Don't wait for reply from server.

-r|--reload              Send reload request - Pragma: no-cache.

-t|--time <sec>          Run benchmark for <sec> seconds. Default 30.

-p|--proxy <server:port> Use proxy server for request.

-c|--clients <n>         Run <n> HTTP clients at once. Default one.

-9|--http09              Use HTTP/0.9 style requests.

-1|--http10              Use HTTP/1.0 protocol.

-2|--http11              Use HTTP/1.1 protocol.

--get                    Use GET request method.

--head                   Use HEAD request method.

--options                Use OPTIONS request method.

--trace                  Use TRACE request method.

-?|-h|--help             This information.

-V|--version             Display program version.

转载于:https://www.cnblogs.com/guarderming/p/10894375.html

Windows 7环境下网站性能测试小工具 Apache Bench 和 Webbench使用和下载相关推荐

  1. 计算机桌面复制到画图,Windows10系统下将画图小工具添加到桌面的技巧

    windows10系统下,用户如果想要使用画图工具的话,都得通过右键-打开方式-画图这种方式来打开,这样不免会有些麻烦.其实,我们只要在Win10系统下把画图小工具添加到桌面就可以了.下面,就随小编看 ...

  2. Android 性能测试小工具 Emmagee

    Emmagee 是一个性能测试小工具 用来监控指定被测应用在使用过程中占用机器的CPU, 内存,流量资源的性能小工具 Emmagee 介绍 Emmagee是网易杭州研究院QA团队开发的一个简单易上手的 ...

  3. 翻译python代码的软件_Linux环境下的Python翻译工具源码

    玩蛇网Python教程源码示例,本文源码是用于Linux环境下的Python翻译工具源码详解. 学习计算机编程语言一定会涉及到英文和学习应用,但通常英语词典在Linux环境下都不如Win环境下的好用. ...

  4. Windows 7环境下ZTE U880 通过PC无线网卡共享上网的详细设置

    Windows 7环境下ZTE U880 通过PC无线网卡共享上网的详细设置 一.环境说明: PC端环境: l  Thinkpad X200 l  WIN7 64X l  无线网卡 手机端: l  Z ...

  5. Windows网络环境下网络规划需要掌握的计算方法(一)

    我是荔园微风,作为一名在IT界整整25年的老兵,今天总结一下Windows网络环境下网络规划必须掌握的技能:网络规划计算.今天先来讲讲第一个知识点,就是如何知道你的网络里有多少数据在跑. 不知道大家有 ...

  6. app的性能测试小工具monkey使用教程

    Monkey app的性能测试小工具monkey使用教程 功能: 是一个稳定性测试(疲劳测试)小工具: 也可以是随机测试小工具 Monkey工具使用过程: A)使用adb shell命令进入到安卓手机 ...

  7. 3 win10环境下安装Pytorch可视化工具Visdom(亲测,欢迎交流)

    0 Win10环境下安装Visdom可视化工具(亲测成功,欢迎交流) Visdom可视化工具: 本文测试安装环境为windows10+Anaconda+python3.7.10 (注意先装好Anaco ...

  8. linux下网站平台的搭建——apache +PHP+mysql

    linux下网站平台的搭建--apache +PHP+mysql 实验环境 VMware 6.5.2+redhat Enterprise 5 AS 我的内核版本 本文实验基础环境已经做好了一个dns的 ...

  9. Windows环境下的命令行工具cmder的安装和使用

    当习惯了Linux环境下的命令行以后,再去使用Windows环境下的命令行,往往会不太顺手.切换为Windows环境和Linux双系统又比较麻烦,现在有一款比较方便的命令行工具,只需安装就可以运行Li ...

最新文章

  1. PaddleOCR,一款文本识别效果不输于商用的Python库!
  2. 网络推广专员浅析如何提升企业网站在网络推广期间的用户体验?
  3. 请举出OSI七层模型在实际应用中的实例
  4. 739. 每日温度 golang
  5. ios开发网络学习:一:NSURLConnection发送GET,POST请求
  6. js页面间通信方法实现
  7. Unity3D研究院之mac上从.ipa中提取unity3D游戏资源
  8. 【二分法】凸多边形外接圆的半径
  9. 夜曲歌词 拼音_夜曲歌词(周杰伦演唱)
  10. html 粘贴 word文档,Word2019文档中粘贴文本的两种方式
  11. Win7 没有声音的解决方法
  12. 直观解释Gamma分布和Poisson分布
  13. 单纤光模块与双纤光模块的区别是什么?
  14. API(15)——打印系统开发(52)——WinForm开发(62)——C#通过调用WinApi打印PDF文档类,服务器PDF打印、IIS PDF打印
  15. vue复选框选中一个全选中了
  16. 如何把Pod本地化(Localize)
  17. 状态模式教你学会清蒸鲤鱼
  18. C语言 加减乘除运算
  19. 第109篇 Compound 中的 Liquidate
  20. 做网络推广中如何通过网站快照提升网站优化效果?

热门文章

  1. 蓝桥杯 ALGO-160 算法训练 P0104
  2. [Java] 蓝桥杯ADV-210 算法提高 2-1屏幕打印
  3. [Python] L1-053 电子汪-PAT团体程序设计天梯赛GPLT
  4. Hive四种数据导入方式介绍
  5. java汉字转拼音的处理
  6. nfs:server 172.168.1.22 not responding,still trying arm客户端配置
  7. 快速搭建Web环境 Angularjs + Express3 + Bootstrap3
  8. 在SQL中用正则表达式替换html标签
  9. Go 统计含 emoji 字符串字符数
  10. 虚拟网络VDC与VPC