How to install Apache JMeter in Ubuntu

After developing a new website, it is very important to perform some tests to find out the limitation of the site, and take necessary actions to remove the limitations for making the site more appropriate for the visitors before publishing. One of the important tests for any website is a load test. How many requests the website can handle at a time or how the website performs when a large number of requests appear on the site can find out by load test.

Apache JMeter is the best tool developed by Stefano Mazzocchi of Apache Software Foundation to perform this type of test and check out the performance of any website. It is used to create a large amount of virtual concurrent traffics to the website for doing the load test. It is open-source software. So anyone can download, install and customize this software to do the test. It is mainly designed for testing web application, but now it is also used for database testing, stress testing, distributed testing, and functional testing. How you can install and run this software is shown in this tutorial.

Install JMeter

JMeter is a developed by Java. So you require to install the latest version of JRE or JDK to run JMeter. If you have installed Java before then run the following command to check the version of the installed Java.

$ java –version

The following output will appear if Java 9 is installed on the system.

If you didn’t install Java before then you can follow the steps from the following tutorial link to install Java before starting the next step.

Go to the following URL location to download the latest version of JMeter. You can download the binary or source file of this tool from this location. Click on ‘’ link to download the binary zip file of JMeter.

Click on Save File radio button and OK button to start the download.

By default, the file will be downloaded in the Downloads folder. Open the folder, right click on the zip file and click on Extract Here from the pop-up menu.

Run JMeter

Press Alt+Ctrl+T to open the terminal and type the following command to go the location from where you can run JMeter.

$ cd Downloads/apache-jmeter-5.0/bin/

Run the following command to run JMeter and open the JMeter dialog box.

$ ./jmeter

The following dialog box will appear after the successful installation of JMeter.

The following dialog box will appear after the successful installation of JMeter.

Simple Test using JMeter

It is discussed earlier that JMeter can be used for various types of testing. How a simple load test can be done using JMeter is shown in this part of the tutorial. Test name is set to Test Plan by default. If you want you can change the default value. Here, Name is set to Test Plan1 and test1 is set as a comment which is optional. Next, you have to set the variables that you want to use in your test. Here, the site is set as the variable name and is set as value. This test will do the load test based on the next configuration of the site

Right-click on Test Plan1 from the left navigation. Click on Add, next Thread (Users) and next Thread Group. It is used to set action, properties, and schedule of Thread Group before starting the test.

In Thread Group, Five types of actions can be taken when any sampler error occurs. These are,

  • Continue
  • Start Next Thread Loop
  • Stop Thread
  • Stop Test
  • Stop Test Now

You can select any of the above actions for your test. Here, the default option is used. Next part of Thread Group is to set Thread Properties. The properties are,

  • Number of Threads (users)
    This property is used to assign the number of virtual visitors that you want for the testing. 15 is set here.
  • Ramp-Up Period (in seconds)
    This property is used to assign the time between two threads. 5 seconds is set here.
  • Loop Count
    This property is used to assign the number of times the thread will run. You can run the thread for unlimited times by selecting Forever checkbox. 1 is set here to run the thread for just one time.

There are other two properties which are “Delay Thread creation until needed” and “Scheduler”. These properties are remained unchecked here. Scheduler Configuration part is used to set the execution time of the test and it will be used in the test if you checked the Scheduler.

Next, you have to set the Sampler type to do the test. Here, HTTP Request is set as Sampler, to hit the server for the resources.

In HTTP Request part, you have to set Web Server, HTTP Request type for the test. You can use HTTP or https as protocol based on your server. By default, HTTP is used. You have to set domain name or IP address of your server in Server Name or IP field. Here, ‘’ domain is used as Server Name. Other values remain as the default value.

Next, you have to set Listener type. It is used to view the test results in various format. Here, ‘View Result in Table’ is selected.

Now, you can click on the start button to start the test based on the assigned configurations. You have to wait for some time to complete the thread in this step.

The following screen will appear after completing the test.


JMeter is a popular testing tool now but this software has some limitations. It consumes more memory while doing the test. It is not good for desktop application and it can’t render HTML and JavaScript like the browser. If you are preparing to publish your website then it is very important to check the performance of your site. You can use JMeter for checking the performance of the site by doing different types of test on it. It will help you to detect the problems of your site and take proper actions to solve it.

ONET IDC thành lập vào năm 2012, là công ty chuyên nghiệp tại Việt Nam trong lĩnh vực cung cấp dịch vụ Hosting, VPS, máy chủ vật lý, dịch vụ Firewall Anti DDoS, SSL… Với 10 năm xây dựng và phát triển, ứng dụng nhiều công nghệ hiện đại, ONET IDC đã giúp hàng ngàn khách hàng tin tưởng lựa chọn, mang lại sự ổn định tuyệt đối cho website của khách hàng để thúc đẩy việc kinh doanh đạt được hiệu quả và thành công.
Bài viết liên quan

Nuclear Music Player – An Electron-based Music Streaming Player

Nuclear Music Player is a nice looking free music streaming app that pulls its content from various free sources all over...

Run Ubuntu 18.04 From USB Stick

Ubuntu 18.04 is a great operating system. It is in beta at the time of this writing. Everyone is so excited and eagerly...

Ubuntu LTS Releases: Everything You Need to Know

Millions of people around the world use Ubuntu as their Linux distribution of choice, and most have wondered at one point...
Bài Viết

Bài Viết Mới Cập Nhật

mua Proxy riêng ở đâu, và nó đem lại lợi ích gì cho người sử dụng

Hướng dẫn sử dụng Proxy Helper Fakeip khi thuê proxy


Mua Proxy Nuôi Zalo Giá Rẻ Tại