Test the Web website performance in CentOS

Source: Internet
Author: User
Tags website performance
Webbench is a well-known test tool for website stress, developed by Lionbridge. Official homepage: http://home.tiscali.cz /~ In the O & M work of cz210552/webbench.html, website stress and performance testing are very important tasks. For example, before a website goes online, the quality of data indicators will directly affect the user experience. However, it is stored in stress and performance tests.

Webbench is a well-known test tool for website stress, developed by Lionbridge.

Official homepage: http://home.tiscali.cz /~ Cz210552/webbench.html

In O & M, website stress and performance testing are very important. For example, before a website goes online, the quality of data indicators will directly affect the user experience. However, there is a commonality in the stress and performance tests, that is, the results of the stress and performance tests are not exactly the same as the actual load results, even if the stress and performance tests are doing well, it cannot be guaranteed that the 100% and online performance indicators are the same. In the face of these problems, we have to try our best to simulate them. Therefore, stress and performance testing are very necessary. With this data, we can be aware of our own maintenance platform.

Web tracking can simulate up to 30 thousand concurrent connections to test the load capacity of the website. Web tracking can test the performance of different services on the same hardware and the running status of the same service on different hardware. The standard Web Bech test shows two items of the server: the number of requests per second and the amount of data transmitted per second. Web tracking can not only test static pages, but also test dynamic pages (ASP, PHP, JAVA, CGI. In addition, it supports static or dynamic performance tests for secure websites with SSL, such as e-commerce websites.

Applicable to linux operating systems

1. Install WebBench:
cd /usr/local/srcwget http://home.tiscali.cz/~cz210552/distfiles/webbench-1.5.tar.gztar zxvf webbench-1.5.tar.gzcd webbench-1.5makemake install

Supplement: If a message is displayed during installation, install the component or create a directory.

 

Common Errors:

Cc-Wall-ggdb-W-O-c-o webbench. o webbench. c

Webbench. c: In function 'arm _ handler ':

Webbench. c: 77: warning: unused parameter 'signal'

Cc-Wall-ggdb-W-O-o webbench. o

Ctags *. c

/Bin/sh: ctags: command not found

Make: [tags] Error 127 (ignored)

Centos has corresponding components. Search for ctags to install it.

# yum install ctags
2. Use webshells:
# Webbench-c 1000-t 60 http://test.cn/info.phpwebbench-c concurrency-t run test time URL
3. Test Result example:
#webbench -c 600 -t 30 http://test.cn/index.phpWebbench - Simple Web Benchmark 1.5Copyright (c) Radim Kolar 1997-2004, GPL Open Source Software.Benchmarking: GET http://test.cn/index.php600 clients, running 30 sec.Speed=12082 pages/min, 152635 bytes/sec.Requests: 6041 susceed, 0 failed.-------------------------------------------------------------------------------------#webbench -c 1000 -t 60 http://test.cn/index.phpWebbench - Simple Web Benchmark 1.5Copyright (c) Radim Kolar 1997-2004, GPL Open Source Software.Benchmarking: GET http://test.cn/index.php1000 clients, running 60 sec.Speed=5553 pages/min, 70152 bytes/sec.Requests: 5553 susceed, 0 failed.

Response requests per second: 24525/60 = X pages/sec. The data volume transmitted per second is 20794612 bytes/sec.

# webbench -c 2000 -t 60 http://test.cn/index.phpWebbench - Simple Web Benchmark 1.5Copyright (c) Radim Kolar 1997-2004, GPL Open Source Software.Benchmarking: GET http://test.cn/index.php2000 clients, running 60 sec.Speed=10479 pages/min, 132043 bytes/sec.Requests: 10453 susceed, 26 failed.

When the concurrency is 2000, it is displayed that 26 connections are failed, indicating that the connection is overloaded.

Supplement:

  1. Stress and performance testing should be conducted before the product is launched, rather than after the product is launched;
  2. During testing, the concurrency should increase gradually from small to small. For example, when the concurrency is 100, check the website load and whether the page is open smoothly, what is concurrency 200, what is concurrency when the website is opened slowly, and what is concurrency when the website cannot be opened;
  3. Perform a Page Test in more detail. e-commerce websites can focus on shopping cart and promotion pages, because these pages account for a large proportion of the total site traffic.

Note: When webbench performs stress and performance tests, the software also consumes CPU and memory resources. To test the accuracy, we recommend that you install webbench on other servers, more accurate test data has been achieved.

Related Article

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.