Create an account

Very important

  • To access the important data of the forums, you must be active in each forum and especially in the leaks and database leaks section, send data and after sending the data and activity, data and important content will be opened and visible for you.
  • You will only see chat messages from people who are at or below your level.
  • More than 500,000 database leaks and millions of account leaks are waiting for you, so access and view with more activity.
  • Many important data are inactive and inaccessible for you, so open them with activity. (This will be done automatically)


Thread Rating:
  • 618 Vote(s) - 3.55 Average
  • 1
  • 2
  • 3
  • 4
  • 5
'jmeter' is not recognized as an internal or external command, operable program or batch file

#1
When i run my JMeter script on commandline mode, i am getting below error.

But the same script is running perfectly fine on GUI mode.

Need some help here to fix this.

Below is the error:

>C:\Users\Sundarapandiyan>jmeter -n -t D:\JMETER\apache-jmeter-3.1\bin\My Projects MyFirstUIRecordBadBoy.jmx -l \JMETER\apache-jmeter-3.1\bin\My Projects CSVSample_user.csv
'jmeter' is not recognized as an internal or external command,
operable program or batch file.
Reply

#2
To directly run a program on the command line it needs to be either included in the [environment PATH][1]; in the same folder; or specified by full path.

To use JMeter via command line you can either:

- Add the folder containing JMeter to your PATH (see

[To see links please register here]

) for how to do this across Windows versions, it's quite generic despite saying JAVA)
- Run it directly from the JMeter folder (in your case D:\JMETER\apache-jmeter-3.1), this is the easiest option for you.
- You can do this by either Shift+Right Clicking in the folder & using 'Open command window here') or;
- Changing to the directory via command line

You can change drive & directory on the command line using:

D:
cd D:\JMETER\apache-jmeter-3.1



[1]:

[To see links please register here]

Reply

#3
As Dave L mentioned, add the Jmeter installation bin directory to the system path using My Computer > properties > Advanced System settings > Environment variables > Under system variables, select PATH > Add D:\JMETER\apache-jmeter-3.1\bin to your path at the end.

Please note, windows only considers the jmeter.bat file even when you run jmeter. It won't run the plain jmeter file available under the installation path.
Reply

#4
If we have space in folder name, the path will get break and you won't be able to run the file.
To overcome this, please use double quotes in the full path.
Example:
C:\Users\Sundarapandiyan>jmeter -n -t "D:\JMETER\apache-jmeter-3.1\bin\My Projects" MyFirstUIRecordBadBoy.jmx -l "path_to_jtl_file"

And also add complete path of jmeter. example:
C:\Users\Sundarapandiyan\Jmeter_folder\bin\jmeter -n -t [rest of the command]
Reply

#5
If you are trying to run JMeter from the command line and are getting an error message stating that “**‘jmeter’ is not recognized as an internal or external command, operable program or batch file**,” it means that JMeter is not in the system path and the system is unable to find it
To solve this issue, you will need to add the path to the JMeter installation to the system path. Here are the steps you can follow:
1. First, locate the installation directory for JMeter. By default, this is usually “C:\apache-jmeter-X.X\bin” (without the quotes), where X.X is the version number of JMeter
2. Next, go to **Start > Control Panel > System and Security > System**
3. Click the Advanced system settings link on the left side of the window
4. Click the **Environment Variables** button
5. Under the System variables section, scroll down and find the **Path** variable
6. Click the Edit button
7. Add the folder location to the Path env variable


**Note**: do not delete any existing values. In case you are using older Windows OS
Add the path to the JMeter installation to the end of the Variable value field. For example, if JMeter is installed in “C:\apache-jmeter-X.X\bin,” you would add “;C:\apache-jmeter-X.X\bin” (without the quotes) to the end of the field

8. Click OK to save the changes
After following these steps, the system should be able to find JMeter and you should be able to run it from the command line without any issues
Reply



Forum Jump:


Users browsing this thread:
1 Guest(s)

©0Day  2016 - 2023 | All Rights Reserved.  Made with    for the community. Connected through