Apache
Apache
Title: To simulate 500 concurrent users and measure the response time of a web page using
Apache JMeter.
Theory
The Apache JMeter™ application is open-source software, a 100% pure Java application designed
to load test functional behavior and measure performance. It was originally designed for testing
Web Applications but has since expanded to other test functions. Apache JMeter may be used to
test performance both on static and dynamic resources, Web dynamic applications. It can be used
to simulate a heavy load on a server, group of servers, network or object to test its strength or to
analyze overall performance under different load types. JMeter is not a browser, it works at
protocol level. As far as web-services and remote services are concerned, JMeter looks like a
browser (or rather, multiple browsers), however JMeter does not perform all the actions supported
by browsers. In particular, JMeter does not execute the JavaScript found in HTML pages. Nor does
it render the HTML pages as a browser does (it's possible to view the response as HTML etc., but
the timings are not included in any samples, and only one sample in one thread is ever displayed
at a time).
Procedure
Step 1: Download and install java from www.java.com/en/download/ before installing JMeter.
Step 2: Download and install Apache JMeter from jmeter.apache.org/download_jmeter.cgi.
➢ Right-click on the Test Plan and choose Add > Threads (Users) > Thread Group.
➢ Number of Threads (Users) Set this to 500 to simulate 500 concurrent users.
➢ Ramp-Up Period (in seconds) This determines how long JMeter will take to start all 500
users. A good practice is to set this to 500 (by default 1 user per second) to avoid
overwhelming the server.
➢ Loop Count: Set this to (1-……….) by default 1 for a single iteration.
Step 6: Add HTTP Request Sampler as
➢ Right-click on the Thread Group, select Add > Sampler > HTTP Request.
➢ Server Name or IP: Enter your web application's domain or IP address. (You want to
simulate).
➢ Port Number: If applicable, specify the port (e.g., 80 for HTTP or 443 for HTTPS).
➢ Path: Enter the path to the login page (e.g., /login).
➢ Method: Select POST (or GET if your login uses that method).
➢ Parameters: Add any required parameters for the login (e.g., username, password).
Step 7: Add a Listener to view results as
➢ Right-click on the Thread Group, select Add > Listener.
➢ Click on view results in tree.
➢ Click on view results in table.