Using siege for Web stress testing

Source: Internet
Author: User

Because recently the company online node project Some unstable situation, consider in this respect can not do further optimization, since to do optimization first need to know where the problem?

Because the temporary cannot locate is the node layer problem or the API layer problem, because in the development environment Small concurrency program run is very stable, later consider using some pressure tools to verify the high concurrency in the time of the problem, here I prefer siege to do stress testing.

One: Installation

The system I use here is FreeBSD, please download the package yourself: http://download.joedog.org/siege/siege-latest.tar.gz

  tar zxvf siege-latest. Tar . GZ      CD Siege-3.0. 9       . /Configure      make doInstall

It's ready to be installed soon.

Check the configuration file

/usr/local/siege/bin/siege-c

Current SIEGE CONFIGURATION
mozilla/5.0 (unknown-x86_64-freebsd10.0) siege/3.0.9
Edit the resource file to the settings.
----------------------------------------------
version:3.0.9
Verbose:true
Quiet:false
Debug:false
protocol:http/1.1
Get Method:head
Connection:close
Concurrent USERS:15
Time to RUN:N/A
repetitions:100
Socket TIMEOUT:30
Accept-encoding:gzip
Delay:1 sec
Internet Simulation:false
Benchmark Mode:false
Failures until abort:1024
Named Url:http://matouapp.ymatou.com/forymatouapp/home
URLs File:/etc/urls.txt
Logging:true
Log file:/var/siege.log
Resource file:/root/.siegerc
timestamped Output:false
Comma separated Output:false
Allow Redirects:true
Allow Zero byte data:true
Allow chunked encoding:true
Upload Unique Files:true

Second, use  

  parameter Description: transactions: Number of requests processed availability: Success rate Elapsed time: How long does it take to Data transferred:   How many bytes are transferred time
    : Response time   Transaction rate: Average number of processing per second (indicates processing speed in the background) throughput: Average transmission speed per second Concurrency: Max concurrency successful TRANSACTI ONS: number of successful processes
Failed transactions: Number of failed processing

 50 users (per concurrency, not concurrency per second) Duplicate 10 generates 50 *10= 500 requests (default: GET)

/usr/local/siege/bin/siege-c 50-r Http://matouapp.ymatou.com/forymatouapp/home

Execution Result:

Using siege for Web stress testing

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.