Ubuntu

How to install Apache JMeter on Ubuntu

This minipost will guide you through all the required steps to successfully install Apache JMeter on Ubuntu 18.04 LTS (Bionic Beaver).

Navigate to Apache JMeter downloads page and download the latest version of the software. At this point, the latest version is Apache JMeter 5.1.1. After the download is finished, go to the downloads directory:

cd ~/Downloads

And extract the file:

tar -xvf apache-jmeter-5.1.1.tgz

Move the directory [apache-jmeter-5.1.1] to the directory you keep all the installed applications:

mv apache-jmeter-5.1.1/ ~/applications

Now, change directory:

cd ~/applications/apache-jmeter-5.1.1/bin

And execute the following:

./jmeter

Apache JMeter GUI will initiate and you will get the following output on the console:

================================================================================
Don't use GUI mode for load testing !, only for Test creation and Test debugging.
For load testing, use NON GUI Mode:
   jmeter -n -t [jmx file] -l [results file] -e -o [Path to web report folder]
& increase Java Heap to meet your test requirements:
   Modify current env variable HEAP="-Xms1g -Xmx1g -XX:MaxMetaspaceSize=256m" in the jmeter batch file
Check : https://jmeter.apache.org/usermanual/best-practices.html
================================================================================

There you go, it’s on! You can now lock it to the Ubuntu launcher to access it easily later.

Finally, let's update the $PATH to have Apache JMeter available in the console from now on:

$ echo 'export PATH="$PATH:$HOME/applications/apache-jmeter-5.1.1/bin"' >> ~/.bashrc

(Note: if you are using zsh, change the above to ~/.zshrc)

Reload your bash by:

$ source ~/.bashrc

(Note: if you are using zsh, change the above to ~/.zshrc)

Give permissions:

chmod +x $HOME/applications/apache-jmeter-5.1.1/bin/jmeter

Finally start JMeter from the console:

jmeter
Buy Me A Coffee