0
votes

I have connected ssh host trough beanshall pre processor java script, after that I have to execute couple(around 20 test cases) of http sampler requests in that same host.

Example: Connected ssh 10.12.38.231:12 username and password Logged above host using javascript Pre processor Next i want to copule of http sampler in same host.

Am able to see logged into host in Jmeter console output But those request running in my local machine not in host.

Is there any way to execute this scenario.

Thanks in advance!

1
Ivank, You need to use master - node concept (i.e., distributed load)to execute the script in the remote machine.Chandra Sekhar Y
Yeah Chandra, we can do that but in my point I have already connected that host from my local Jmeter. Is there any chance execute from localIvank
If you need to execute the Jmeter script in another machine, that machine need to have jmeter setup in it. We can do your requirement in Two ways 1) You can use Distributed Load Concept 2) You need to setup Jmeter on another remote machine and also the script you need to execute on it. Then You can execute the script from main machine using commands of Non-GUI. This way you can run the script on remote machine from another machine using command lineChandra Sekhar Y

1 Answers

0
votes

If you want to connect to the remote machine over SSH and run the requests on that remote machine you have 2 options:

  1. Transferring the JMeter test plan from the local machine to the remote one using i.e. SSH SFTP sampler
  2. Installing JMeter onto that machine and kicking off the test in command-line non-GUI mode using SSH Command sampler

Both samplers can be installed as a part of SSH Protocol Support bundle using JMeter Plugins Manager

enter image description here


Also forget about Beanshell, since JMeter 3.1 you should be using JSR223 Test Elements and Groovy language for scripting.