First download the KEYS as well as the asc signature file for the relevant distribution. Make sure you get these files from the main distribution site, rather than from a mirror. Windows 7 and later systems should all now have certUtil:% certUtil -hashfile pathToFileToCheck. HashAlgorithm choices: MD2 MD4 MD5 SHA1 SHA256 SHA384 SHA512. Installing Plugins. The easiest way to get the plugins is to install Plugins Manager. Then you'll be able to install any other plugins just by clicking a checkbox. Download plugins-manager.jar and put it into lib/ext directory, then restart JMeter. If you experience any issues with plugins installation, don't hesitate to ask at Support Forums. Download Apache JMeter: We recommend you use a mirror to download our release builds, but you must verify the integrity of the downloaded files using signatures downloaded from our main distribution directories. Recent releases (48 hours) may not yet be available from the mirrors. Download from the middle of this page a JMeter Binary file such as apache-jmeter-2.11.zip for Windows machines. Download.tgz for use on Linux or Apple Macs. Installer files have grown over the years 2.3.2.zip created 6/10/2008 was 16.6 MB. 2.11.zip created 6/10/2014 was 31.2 MB (6 years later). In this article we use JMeter version 2.1. Download a binary executable from the Web site, unzip it, and the application is ready for use on Windows or Unix platforms. Go to the bin folder and start the application with jmeter.bat or jmeterw.bat if you work on the Windows operating system. The initial user interface is.
JMeter is a Load-Testing Tool used for Performance Testing. A Performance Tester can record actions in a web browser or manually build a script which can then be run with hundreds or thousands of users.
JMeter can be used to create incredibly dynamic users and scenarios using its various elements. For instance, the
CSV Data Set Config can be used to specify a set of users to log into a web application. The
Regular Expression Extractor or the CSS/JQuery Extractor can be used to save session ids to be used in future requests. The
JSR223 PreProcessor coupled to Groovy language can be used to create dynamic unique data for each user to be sent as part of a
|Version||Java Version||Release Date|
Installation or Setup
Download a distributed archive from Binaries section of JMeter from Download Apache JMeter page.
Depending on the version you downloaded, check minimal Java version requirements and install Java if needed. Ensure the
JAVA_HOMEenvironment variable is set and points to a correct version.
Extract the distribution archive in the directory of your choice.
Open JMeter UI:
On Windows: navigate to
<jmeter_location>bindirectory and run
On Linux/Mac: navigate to
<jmeter_location>/bindirectory and run
Note: if the above command fails with
Permission deniederror, set execute permission on
If you are able to see JMeter UI, basic setup was successful.
Overview of Apache JMeter components at high level
Apache JMeter segregated all the components into following groups based on their functionality:
Test Plan: Starting point for scripting. JMeter saves the Test Plan in .jmx format. You add components to the Test Plan by Right Click on the Test Pand and navigating to the component you want to add.
Workbench: Is a temporary place to start scripting. Along with all the components available in Test Plan, you get
HTTP(s) Test Script Recorderin order to
recordthe browser actions. Scripts can be saved in the Workbench provided you check the 'Save Workbench' checkbox, otherwise they are no.
Threads (Users): you can define a number of (virtual) users to run, ramp-up time and loop count. you can also define on Test Plan whether Thread Groups need to run in sequential or parallel in the case of multiple Thread Groups. some examples are
Thread Group, setUp Thread Group, and tearDown Thread Group
Logic Controller: Allows you define the flow of execution and grouping of the samplers. one of the useful examples is Transaction Controller, where you combine all the samplers of Login page (all resources including images, .css, and .js files) so that combined response time can be retrieved.
Sampler: Sampler is the core of the JMeter. It gives components to simulate requests of various protocols such as HTTP, JDBC, FTP, SMTP etc. for example, HTTP sampler allows you simulate an HTTP packet (of GET, POST or any supported methods). Main stream protocols are supported, for others you can use Free or Commercial plugins.
Config Element: Configuration elements can be used to set up defaults and variables for later use by samplers. Note that these elements are usually processed at the start of the scope in which they are found, i.e. before any samplers in the same scope.
CSV Dataset Configallows you to provide test data like usernames, passwords of Login scenario
from a file.
User Defined variablesconfig element allows you define variables which can be used across the Test Plan but where each Thread has its own copy.
Timer: By default, a JMeter thread executes samplers in sequence without pausing. Components presented here provide the functionality to introduce
User Think Timein various forms among samplers. some examples are
Constant Timer, Constant Throughput Timer.
Pre Processors: allow you to perform operations/actions before sampler gets executed.
JSR223 Pre Processorwith Apache Groovy (similar to java coding style) allows you to make changes to the sampler before sending it.
Post Processors: allow you perform operations/actions after sampler get executed. some useful examples are retrieving dynamic value such as Session ID, using
Regular Expression Extractorpost processor for any type of text,
CSS/JQuery Extractorfor HTML,
JSON Extractorfor JSON,
XPath Extractorfor XML.
Assertions: As the name suggests, you can assert the response of samplers in different ways like searching for some text, the size of the response, and duration to receive the response etc. For example, you can use
Response Assertionto search for some text in the response. If Assertion fails, JMeter marks the sampler, to which Assertion is applied, as Failure.
- Listeners: Listeners allow you to save the test results, see the test execution etc. for example, using
View Results Tree, you can see the samplers request/response and whether they marked as PASS (green colour)/FAIL (red colour) by JMeter. using Aggregate Report, you can save the test results in CSV format. Important note is that, you use listeners either before the test run (for test script debug) or after the test run (to view results in graphs or summary) but not during the run. we must remove the listeners during the test as it consume a lot of system resources. So, we run the test in non-GUI mode and save the results using
.csv/.jtlformats. Post the test, you can load this saved files into any of the listeners in the JMeter to view graphs/summary.
Following is the general syntax (
you add any component on need basis ):
JMeter is a pure Java based Performance Testing tool which is developed by Apache Foundation. It is used for testing and analyzing the overall performance of System under different types of load. Considering the usability, it is the best tool among its competitors as it provides user friendly GUI which makes it easy to use.
Download Jmeter 5.2.1Launch the Jmeter by running Windows Batch file which you can find in apache-jmeter-2.11binjmeter.batchAfter launching the batch file, you can see the Jmeter window as shown below.There are main two component of Jmeter which you can see in above screen.
- Test Plan – a container of elements used to test performance of any system.
- WorkBench – is a working area which cannot be saved. It includes non-test elements like HTTP mirror server, HTTP(S) Test Script Recorder.
Following is the list of essential test elements which are required for initialization of performance testing.
1. Thread GroupThread Group is a pool of virtual users. It defines the number of requests to be sent to the server. You can add this by right click on Test Plan → Add → Threads (Users) → Thread Group. It is a required element if you are dealing with Sampler. Once you add the Thread Group it will look like below screen.
- Name : You can change the name of Thread Group by changing the text in Name text field.
- Comment : You can add comments to Thread group.
- Action to be taken after a Sampler error : You can control the thread when error occurred by selecting radio button.
- Thread Properties : You can define the number of virtual users.
- Ram-Up period : It is the time when all thread request has been sent. Suppose you configured properties as 5 users, and you define Ramp-Up time as 5 then each request will be sent after 1 second. So all the request will be sent in 5 seconds.
- Loop Count : You can also create loop of request by defining Loop count.