網站性能測試工具 webbench 的安裝和使用

1.webbench下載和安裝

wget http://home.tiscali.cz/~cz210552/distfiles/webbench-1.5.tar.gz

sudo tar xvf webbench-1.5.tar.gz  -C /usr/local/

cd /usr/local/webbench-1.5/

 

sudo apt -y install make ctags gcc

sudo make

sudo make install

 

2.命令幫助及說明

01-webbench測試工具的使用.jpg 

命令行選項:

短參 長參數 作用

-f --force 不需要等待服務器響應

-r --reload 發送重新加載請求

-t --time 運行多長時間,單位:秒"

-p --proxy server:port 使用代理服務器來發送請求

-c --clients 創建多少個客戶端,默認1"

-9 --http09 使用 HTTP/0.9

-1 --http10 使用 HTTP/1.0 協議

-2 --http11 使用 HTTP/1.1 協議

--get     使用 GET請求方法 

--head 使用 HEAD請求方法

--options 使用 OPTIONS請求方法

--trace 使用 TRACE請求方法

-?/-h --help 打印幫助信息

-V --version 顯示版本號

 

3.命令使用

catty@server8:/usr/local/webbench-1.5$ webbench -c 100 -t 5 http://192.168.3.162:9999/

Webbench - Simple Web Benchmark 1.5

Copyright (c) Radim Kolar 1997-2004, GPL Open Source Software.

 

Benchmarking: GET http://192.168.3.162:9999/

100 clients, running 5 sec.

 

Speed=142920 pages/min, 27096180 bytes/sec.

Requests: 11910 susceed, 0 failed.

catty@server8:/usr/local/webbench-1.5$

# -c 100 模擬100個用戶同時請求,

# -t 5 持續5秒鐘發送請求

# 結果分析:

# 網站性能 Speed=142920 pages/min=2382pages/sec

# 網絡速度 27096180 bytes/sec=27MB/s

# 總請求數 Requests: 11910 susceed

 

4.軟件介紹

 

官方網址:http://home.tiscali.cz/~cz210552/webbench.html 

 

Web Bench 1.5

Registered on freshmeat.net as project web-bench.

Web Bench is very simple tool for benchmarking WWW or proxy servers. Uses fork() for simulating multiple clients and can use HTTP/0.9-HTTP/1.1 requests. This benchmark is not very realistic, but it can test if your HTTPD can realy handle that many clients at once (try to run some CGIs) without taking your machine down. Displays pages/min and bytes/sec. Can be used in more aggressive mode with -f switch.

 

Program: Web Bench

Version: 1.5

Updated: Jun 25 2004 (最後更新時間是2004年)

Platform: Posix C

File: webbench-1.5.tar.gz (7675 bytes)

 

其他介紹:https://github.com/EZLippi/WebBench 

WebbenchRadim Kolar1997年寫的一個在linux下使用的非常簡單的網站壓測工具。它使用fork()模擬多個客戶端同時訪問我們設定的URL,測試網站在壓力下工作的性能,最多可以模擬3萬個併發連接去測試網站的負載能力。

 

 


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