RHEL BasedRocky Linux

How To Install Apache JMeter on Rocky Linux 9

Install Apache JMeter on Rocky Linux 9

In this tutorial, we will show you how to install Apache JMeter on Rocky Linux 9. For those of you who didn’t know, Apache JMeter is a powerful open-source tool designed for load testing and measuring the performance of web applications, APIs, and other software systems. As a Java-based application, JMeter is highly versatile and can be run on various operating systems, including the robust and secure Rocky Linux 9.

This article assumes you have at least basic knowledge of Linux, know how to use the shell, and most importantly, you host your site on your own VPS. The installation is quite simple and assumes you are running in the root account, if not you may need to add ‘sudo‘ to the commands to get root privileges. I will show you the step-by-step installation of the Apache JMeter on Rocky Linux 9 or RHEL-based.


  • A server running one of the following operating systems: Rocky Linux 9.
  • It’s recommended that you use a fresh OS install to prevent any potential issues.
  • Sufficient disk space and memory to accommodate JMeter and its components.
  • SSH access to the server (or just open Terminal if you’re on a desktop).
  • An active internet connection. You’ll need an internet connection to download the necessary packages and dependencies.
  • A non-root sudo user or access to the root user. We recommend acting as a non-root sudo user, however, as you can harm your system if you’re not careful when acting as the root.

Install Apache JMeter on Rocky Linux 9

Step 1. Update Your System.

To begin, update your Rocky Linux 9 system to the latest packages and security patches by running the following command:

sudo dnf update

This command ensures that your system is up-to-date and ready for the JMeter installation.

Step 2. Installing Java.

Apache JMeter is built on the Java platform, making it essential to have Java installed on your Rocky Linux 9 system. To check if Java is already installed, run the following command:

java -version

If Java is not installed, you can easily install OpenJDK 11, an open-source implementation of the Java Development Kit, by executing the following command:

sudo dnf install java-11-openjdk

Step 3. Installing Apache JMeter on Rocky Linux 9.

To download the latest version of Apache JMeter, visit the official Apache JMeter download page. Locate the latest stable release and copy the download link for the ZIP archive.

Alternatively, you can use the wget command to download JMeter directly from the command line. Run the following command, replacing the URL with the latest version:

wget https://dlcdn.apache.org//jmeter/binaries/apache-jmeter-5.6.3.zip

This command will download the JMeter ZIP archive to your current directory. Verify the integrity of the downloaded file by comparing its checksum with the one provided on the download page.

Once the JMeter ZIP archive is downloaded, navigate to the directory where it was saved. Typically, this would be the ~/Downloads directory. Use the following command to navigate:

cd ~/Downloads

Next, extract the contents of the ZIP archive using the unzip command:

unzip apache-jmeter-5.6.3.zip

To keep your system organized and maintain a standard directory structure, move the extracted directory to the /opt directory using the following command:

sudo mv apache-jmeter-5.6.3 /opt/jmeter

To ensure that Apache JMeter is accessible from anywhere in the terminal, you need to set up environment variables. This step involves adding the JMeter bin directory to the system’s PATH variable.

Open the .bashrc file in your home directory using a text editor like nano:

nano ~/.bashrc

Scroll to the bottom of the file and add the following lines:

export JMETER_HOME="/opt/jmeter"
export PATH="$JMETER_HOME/bin:$PATH"

Save the changes and exit the text editor. To apply the changes immediately, run the following command:

source ~/.bashrc

Verify the setup by running the jmeter --version command, which should display the installed JMeter version.

Step 4. Running JMeter

Apache JMeter can be run in two modes: GUI mode and non-GUI mode. The GUI mode is ideal for creating and debugging test plans, while the non-GUI mode is used for running load tests without the overhead of the graphical interface.

To launch JMeter in GUI mode, simply run the following command:


This command will open the JMeter graphical user interface, allowing you to create, edit, and run test plans.

Install Apache JMeter on Rocky Linux 9

For running load tests in non-GUI mode, use the following command:

jmeter -n -t testPlan.jmx -l log.jtl

Replace testPlan.jmx with the path to your JMeter test plan file and log.jtl with the desired name for the test results log file.

Congratulations! You have successfully installed Apache JMeter. Thanks for using this tutorial for installing the Apache JMeter on your Rocky Linux 9 system. For additional help or useful information, we recommend you check the official Apache website.

VPS Manage Service Offer
If you don’t have time to do all of this stuff, or if this is not your area of expertise, we offer a service to do “VPS Manage Service Offer”, starting from $10 (Paypal payment). Please contact us to get the best deal!


r00t is a seasoned Linux system administrator with a wealth of experience in the field. Known for his contributions to idroot.us, r00t has authored numerous tutorials and guides, helping users navigate the complexities of Linux systems. His expertise spans across various Linux distributions, including Ubuntu, CentOS, and Debian. r00t's work is characterized by his ability to simplify complex concepts, making Linux more accessible to users of all skill levels. His dedication to the Linux community and his commitment to sharing knowledge makes him a respected figure in the field.
Back to top button