您的位置:首页 > 运维架构 > Linux

linux下web压力测试工具siege的使用

2014-11-19 11:33 561 查看
linux下得web压力测试工具,最常用的应该就是apache的ab了,当然可供选择的有很多。webbench,http_load。看你个人爱好了。不过,最近,用的最顺手的是siege。
siege官网地址http://www.joedog.org/
,最新版本3.0.8,下载地址http://download.joedog.org/siege/

1、安装
wget http://download.joedog.org/siege/siege-3.0.8.tar.gz

tar xzvf siege-3.0.8.tar.gz
cd siege-3.0.8
./configure
make && make install

2、准备测试url或者url列表文件

3、跑起
siege www.jumei.com/test.php -b -r10 -c400

参数说明:
-b --benchmark BENCHMARK: no delays between requests.
每次request之间没有延迟,还有一个-d参数加上延迟,类似于一些专业测试工具的思考时间
-r --reps=NUM REPS, number of times to run the test.

每次请求执行多少次
-c --concurrent=NUM CONCURRENT users, default is 10
并发用户
-f --file=FILE FILE, select a specific URLS FILE.

4、执行结果

Transactions: 3915 hits
Availability: 97.88 %
Elapsed time: 43.73 secs
Data transferred: 706.12 MB
Response time: 2.90 secs
Transaction rate: 89.53 trans/sec
Throughput: 16.15 MB/sec
Concurrency: 259.48
Successful transactions: 3915
Failed transactions: 85
Longest transaction: 37.70
Shortest transaction: 0.05
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签:  linux 压力测试 siege
相关文章推荐