http接口壓力測試
c編寫的多進程測試http接口壓力工具。
編譯
下載鏈接: https://github.com/EZLippi/WebBench.git
yum install -y gcc
yum install -y ctag
yum install -y libtirpc
yum install -y libtirpc-devel
使用centos8 gcc8.3.1編譯時注釋 #include <rpc/types.h>;直接make進行編譯
使用
webbench -c 1000 -t 60 http://www.baidu.com/
- -c 多少個客戶端同時并發(fā)
- -t 并發(fā)時間
- -9 使用HTTP/0.9協(xié)議
- -1 使用HTTP/1.0協(xié)議
- -2 使用HTTP/1.1協(xié)議
[test@qnsd workbench]$ ./webbench -c 10 -t 2 http://www.baidu.com/
Webbench - Simple Web Benchmark 1.5
Copyright (c) Radim Kolar 1997-2004, GPL Open Source Software.
Benchmarking: GET http://www.baidu.com/
10 clients, running 2 sec.
Speed=749 pages/min, 4028702 bytes/sec.
Requests: 25 susceed, 0 failed.