Bug Description Unable to open JMeter in non GUI mode. Steps to reproduce: 1.open cmd . 2.To open JMeter in server mode, run the bat file bin\jmeter-server.bat.
Expected result: JMeter Starts in cmd.
Actualresult:
Problem URL:
... Trying JMETER_HOME=..
Found ApacheJMeter_core.jar
Sep 12, 2018 1:33:34 PM java.util.prefs.WindowsPreferences <init>
WARNING: Could not open/create prefs root node Software\JavaSoft\Prefs at root 0x80000002. Windows RegCreateKeyEx(...) returned error code 5.
Server failed to start: java.rmi.server.ExportException: Listen failed on port: 0; nested exception is:
java.io.FileNotFoundException: rmi_keystore.jks (The system cannot find the file specified)
An error occurred: Listen failed on port: 0; nested exception is:
java.io.FileNotFoundException: rmi_keystore.jks (The system cannot find the file specified)
errorlevel=1
Press any key to continue . . .
C:\Users\rozeena.ibrahim>d:
D:\>cd apache-jmeter-4.0
D:\apache-jmeter-4.0>cd bin
D:\apache-jmeter-4.0\bin>jmeter-server.bat
Could not find ApacheJmeter_core.jar ...
... Trying JMETER_HOME=..
Found ApacheJMeter_core.jar
Sep 12, 2018 1:34:12 PM java.util.prefs.WindowsPreferences <init>
WARNING: Could not open/create prefs root node Software\JavaSoft\Prefs at root 0x80000002. Windows RegCreateKeyEx(...) returned error code 5.
Server failed to start: java.rmi.server.ExportException: Listen failed on port: 0; nested exception is:
java.io.FileNotFoundException: rmi_keystore.jks (The system cannot find the file specified)
An error occurred: Listen failed on port: 0; nested exception is:
java.io.FileNotFoundException: rmi_keystore.jks (The system cannot find the file specified)
errorlevel=1
Press any key to continue . . .
This is not a bug, since JMeter 4.0 communication between master and slaves is secure (maybe to prevent possible intruders from intercepting JMeter .jtl result file and dying of laughter seeing your system performance metrics) so you need to generate the keystore using create-rmi-keystore.bat
first on master and all the slaves.
Alternatively you can disable this piece of functionality and revert back to previous JMeter behaviour by adding the next line to user.properties file:
server.rmi.ssl.disable=true
the change will be permanent, if you want to do it only once - it is better to pass the property via -J command-line argument like:
jmeter-server.bat -Jserver.rmi.ssl.disable=true
More information:
If you just want to run jmeter in NON GUI mode then do this:
jmeter -n -t jmxplan -l results.csv
But if you really want to use distributed testing, then since JMeter 4.0 the default transport mechanism for RMI will use SSL. SSL needs keys and certificates to work. You will have to create those keys yourself. You must create the rmi_keystore.jks as per error message.
JMeter comes with a script to generate a keystore that contains one key (and its corresponding certificate) named rmi. The script is located in the bin directory and is available for Windows systems (called bin/create-rmi-keystore.bat) and Unix like systems (called bin/create-rmi-keystore.sh).
It will generate a key-pair, that is valid for seven days, with a default passphrase of value 'changeit'. It is advised to call it from inside the bin directory. See:
Note that disabling SSL mode would be a security issue, so although possible it is not advised
User contributions licensed under CC BY-SA 3.0