<rt id="bn8ez"></rt>
<label id="bn8ez"></label>

  • <span id="bn8ez"></span>

    <label id="bn8ez"><meter id="bn8ez"></meter></label>

    隨筆-204  評論-90  文章-8  trackbacks-0

    Siege(英文意思是圍攻)是一個壓力測試和評測工具,設計用于WEB開發這評估應用在壓力下的承受能力:可以根據配置對一個WEB站點進行多用戶的并發訪問,記錄每個用戶所有請求過程的相應時間,并在一定數量的并發訪問下重復進行。


    最早使用的壓力測試工具是apache的ab(apache benchmark),apache ab做重復壓力測試不錯,但是每次只能測試一個鏈接,如何測試一組鏈接(比如從日志中導出的1個小時的日志,做真實壓力測試),后來找到了這個:
    Siege是一個壓力測試和評測工具,設計用于WEB開發這評估應用在壓力下的承受能力:可以根據配置對一個WEB站點進行多用戶的并發訪問,記錄每個用戶所有請求過程的相應時間,并在一定數量的并發訪問下重復進行。
    SIEGE is an http regressive testing and benchmarking utility. It was designed to let web developers measure the performance of their code under duress, to see how it will stand up to load on the internet. It lets the user hit a webserver with a configurable number of concurrent simulated users. Those users place the webserver "under siege." The duration of the siege is measured in transactions, the sum of simulated users and the number of times each simulated user repeats the process of hitting the server. Thus 20 concurrent users 50 times is 1000 transactions, the length of the test.

    下載/安裝
    Siege時一個開放源代碼項目:http://www.joedog.org

    下載:
    wget ftp://sid.joedog.org/pub/siege/siege-latest.tar.gz

    安裝:
    %./configure ; make
    #make install

    siege包含了一組壓力測試工具:
    SIEGE (1) Siege是一個HTTP壓力測試和評測工具.
    使用樣例:
    任務列表:www.chedong.com.url文件
    http://www.chedong.com/tech/
    http://www.chedong.com/tech/acdsee.html
    http://www.chedong.com/tech/ant.html
    http://www.chedong.com/tech/apache_install.html
    http://www.chedong.com/tech/awstats.html
    http://www.chedong.com/tech/cache.html
    http://www.chedong.com/tech/click.html
    http://www.chedong.com/tech/cms.html
    http://www.chedong.com/tech/compress.html
    http://www.chedong.com/tech/cvs_card.html
    http://www.chedong.com/tech/default.html
    http://www.chedong.com/tech/dev.html
    http://www.chedong.com/tech/gnu.html
    ....

    siege -c 20 -r 2 -f www.chedong.com.url
    參數說明:
    -c 20 并發20個用戶
    -r 2 重復循環2次
    -f www.chedong.com.url 任務列表:URL列表

    輸出樣例:

    ** Siege 2.59
    ** Preparing 20 concurrent users for battle. 這次“戰斗”準備了20個并發用戶
    The server is now under siege.. done. 服務在“圍攻”測試中:
    Transactions: 40 hits 完成40次處理
    Availability: 100.00 % 成功率
    Elapsed time: 7.67 secs 總共用時
    Data transferred: 877340 bytes 共數據傳輸:877340字節
    Response time: 1.65 secs 相應用時1.65秒:顯示網絡連接的速度
    Transaction rate: 5.22 trans/sec 平均每秒完成5.22次處理:表示服務器后臺處理的速度
    Throughput: 114385.92 bytes/sec 平均每秒傳送數據:114385.92字節
    Concurrency: 8.59 最高并發數 8.59
    Successful transactions: 40 成功處理次數
    Failed transactions: 0 失敗處理次數

    注意:由于速度很快,可能會達不到并發速度很高就已經完成。Response time顯示的是測試機器和被測試服務器之間網絡鏈接狀況。Transaction rate則表示服務器端任務處理的完成速度。

    輔助工具:
    增量壓力測試:


    為了方便增量壓力測試,siege還包含了一些輔助工具:
    bombardment (1)
    是一個輔助工具:用于按照增量用戶壓力測試:
    使用樣例:
    bombardment urlfile.txt 5 3 4 1
    初始化URL列表:urlfile.txt
    初始化為:5個用戶
    每次增加:3個用戶
    運行:4次
    每個客戶端之間的延遲為:1秒

    輸出成CSV格式:
    siege2csv.pl (1)
    siege2csv.pl將bombardment的輸出變成CSV格式:
    Time Data Transferred Response Time Transaction Rate Throughput Concurrency Code 200 (note that this is horribly broken.)
    242 60.22 603064 0.02 4.02 10014.35 0.08
    605 59.98 1507660 0.01 10.09 25136.05 0.12
    938 59.98 2337496 0.02 15.64 38971.26 0.26
    1157 60 2883244 0.04 19.28 48054.07 0.78

    參考:
    開源測試工具:http://www.opensourcetesting.org/performance.php

    壓力測試工具:HammerHead 正在試用中

    posted on 2007-09-20 17:56 一凡 閱讀(359) 評論(0)  編輯  收藏 所屬分類: linux
    主站蜘蛛池模板: 国产成人精品久久亚洲高清不卡 | 国产亚洲精品观看91在线| 亚洲第一成年人网站| 亚洲熟妇AV乱码在线观看| 国产精品极品美女自在线观看免费| 99精品视频在线视频免费观看| 国产成人免费A在线视频| 亚洲色偷偷色噜噜狠狠99网| 处破痛哭A√18成年片免费| 亚洲av无码成人影院一区| 久久久精品午夜免费不卡| 免费a级毛片网站| 亚洲综合丁香婷婷六月香| 无码少妇一区二区浪潮免费| 亚洲真人无码永久在线观看| 国产精品国产免费无码专区不卡 | 亚洲ⅴ国产v天堂a无码二区| 日韩国产欧美亚洲v片| 亚洲高清无码专区视频| a级毛片毛片免费观看久潮喷 | 国产免费久久精品丫丫| 国产成人免费a在线视频app| 少妇亚洲免费精品| 亚洲成av人片一区二区三区| 国产一级一毛免费黄片| 久久精品国产亚洲精品| 在线亚洲v日韩v| 国产精品美女自在线观看免费| 粉色视频在线观看www免费| 国产精品亚洲美女久久久| 久操免费在线观看| 一本色道久久88亚洲精品综合| 亚洲国产精品成人AV无码久久综合影院| 99麻豆久久久国产精品免费| 亚洲国产成人久久三区| 四虎免费影院ww4164h| 免费播放美女一级毛片| 亚洲色欲www综合网| 亚洲人成人网站在线观看| jizz免费在线观看| 亚洲一区二区三区精品视频|