{"id":835,"date":"2016-05-10T11:27:34","date_gmt":"2016-05-10T11:27:34","guid":{"rendered":"https:\/\/loadfocus.com\/blog\/?p=835"},"modified":"2024-04-25T20:52:44","modified_gmt":"2024-04-25T20:52:44","slug":"how-to-start-apache-jmeter-in-non-graphical-non-gui-mode","status":"publish","type":"post","link":"https:\/\/loadfocus.com\/blog\/2016\/05\/how-to-start-apache-jmeter-in-non-graphical-non-gui-mode","title":{"rendered":"How to start Apache JMeter in non-graphical (non-GUI) mode?"},"content":{"rendered":"<span class=\"span-reading-time rt-reading-time\" style=\"display: block;\"><span class=\"rt-label rt-prefix\"><\/span> <span class=\"rt-time\"> 2<\/span> <span class=\"rt-label rt-postfix\">minutes read<\/span><\/span><p class=\"lead\">If you want to start Apache JMeter in non-GUI mode, use the following command line options:<\/p>\n<ul>\n<li><em>-n<\/em> &#8211; non-GUI mode &#8211; this specifies JMeter is to run in non-GUI mode<\/li>\n<li><em>-t<\/em> &#8211; JMX file &#8211; location of the test plan and the name of JMX file that contains the Test Plan<\/li>\n<li><em>-l<\/em> &#8211; log file name of JTL file to log sample results to<\/li>\n<\/ul>\n<h3>Example<\/h3>\n<pre>jmeter -n -t my_test_plan.jmx -l log.jtl<\/pre>\n<h4>Optional<\/h4>\n<ul>\n<li><em>-j<\/em> &#8211; name of JMeter run log file<\/li>\n<li><em>-r<\/em>\u00a0&#8211; Run the test in the servers specified by the JMeter property &#8220;remote_hosts&#8221;<\/li>\n<li><em>-R &#8211;<\/em>\u00a0list of remote servers Run the test in the specified remote servers<\/li>\n<li><em>-H &#8211;<\/em>\u00a0proxy server hostname or ip address<\/li>\n<li><em>-P &#8211;<\/em>\u00a0proxy server port<\/li>\n<\/ul>\n<h3>Example<\/h3>\n<pre>jmeter -n -t my_test_plan.jmx -l log.jtl -H my.proxy.server -P 8000<\/pre>\n<h4>Tips for running JMeter in non-GUI mode:<\/h4>\n<ul>\n<li>here are details on <a href=\"https:\/\/loadfocus.com\/blog\/2016\/04\/16\/how-to-add-jmeter-to-the-path-environment-variable-on-mac-os-x\/\">how to add <em>jmeter\u00a0<\/em>to the PATH variable<\/a> of your environment<\/li>\n<li>remove any listeners that are GUI mode specific (you can do this by opening your JMX file in GUI mode and remove the GUI specific listeners)<\/li>\n<li>get summary results in the terminal by activating the summary option in the jmeter.properties file<\/li>\n<\/ul>\n<p>Additional scripts that come with Apache JMeter installation can be found in the<em> \/bin<\/em> folder where you&#8217;ve downloaded JMeter.<\/p>\n<h4>For Windows systems:<\/h4>\n<ul>\n<li><em>jmeter-n.cmd<\/em> &#8211; drop a JMX file on this to run a non-GUI test<\/li>\n<li><em>jmeter-n-r.cmd<\/em> &#8211; drop a JMX file on this to run a non-GUI test remotely<\/li>\n<li><em>mirror-server.cmd<\/em> &#8211; runs the JMeter Mirror Server in non-GUI mode<\/li>\n<li><em>shutdown.cmd<\/em> &#8211; Run the Shutdown client to stop a non-GUI instance gracefully<\/li>\n<li><em>stoptest.cmd<\/em> &#8211; Run the Shutdown client to stop a non-GUI instance abruptly<\/li>\n<\/ul>\n<h4>For Unix\/Linux systems:<\/h4>\n<ul>\n<li><em>mirror-server.sh<\/em> &#8211; runs the JMeter Mirror Server in non-GUI mode<\/li>\n<li><em>shutdown.sh<\/em> &#8211; Run the Shutdown client to stop a non-GUI instance gracefully<\/li>\n<li><em>stoptest.sh<\/em> &#8211; Run the Shutdown client to stop a non-GUI instance abruptly<\/li>\n<\/ul>\n<p>The commands will only be accepted if the scripts are run from the same host. Details on <a href=\"https:\/\/loadfocus.com\/blog\/2014\/06\/24\/run-apache-jmeter-on-mac\/\">how to start JMeter on Mac<\/a> system can be found here. Also, here is\u00a0how to load test a website with Apache JMeter.<\/p>\n","protected":false},"excerpt":{"rendered":"<p><span class=\"span-reading-time rt-reading-time\" style=\"display: block;\"><span class=\"rt-label rt-prefix\"><\/span> <span class=\"rt-time\"> 2<\/span> <span class=\"rt-label rt-postfix\">minutes read<\/span><\/span>If you want to start Apache JMeter in non-GUI mode, use the following command line options: -n &#8211; non-GUI mode &#8211; this specifies JMeter is to run in non-GUI mode -t &#8211; JMX file &#8211; location of the test plan and the name of JMX file that contains the Test Plan -l &#8211; log file&#8230;  <a href=\"https:\/\/loadfocus.com\/blog\/2016\/05\/how-to-start-apache-jmeter-in-non-graphical-non-gui-mode\" class=\"more-link\" title=\"Read How to start Apache JMeter in non-graphical (non-GUI) mode?\">Read more &raquo;<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[8,9,6],"tags":[143,141,142],"class_list":["post-835","post","type-post","status-publish","format-standard","hentry","category-apache-jmeter","category-load-testing","category-performance-testing","tag-command-to-run-jmeter-in-non-gui-mode","tag-jmeter-in-non-gui-mode","tag-running-jmeter-in-non-gui-mode"],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/loadfocus.com\/blog\/wp-json\/wp\/v2\/posts\/835","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/loadfocus.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/loadfocus.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/loadfocus.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/loadfocus.com\/blog\/wp-json\/wp\/v2\/comments?post=835"}],"version-history":[{"count":1,"href":"https:\/\/loadfocus.com\/blog\/wp-json\/wp\/v2\/posts\/835\/revisions"}],"predecessor-version":[{"id":2997,"href":"https:\/\/loadfocus.com\/blog\/wp-json\/wp\/v2\/posts\/835\/revisions\/2997"}],"wp:attachment":[{"href":"https:\/\/loadfocus.com\/blog\/wp-json\/wp\/v2\/media?parent=835"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/loadfocus.com\/blog\/wp-json\/wp\/v2\/categories?post=835"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/loadfocus.com\/blog\/wp-json\/wp\/v2\/tags?post=835"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}