I'm doing remote testing on 2 slave machines on Linux in CLI mode. I have set the rmi ports as below on both Master and slave machines. I'm able to telnet to ports 8080/1099 from master-slave and vice versa. Firewall is opened for these ports.
jmeter.properties:client.rmi.localport=1099
jmeter.properties:server.rmi.localport=8080
I started the jmeter-server on both master and slave nodes
./jmeter-server -Djava.rmi.server.hostname=10.132.89.172 (Master)
./jmeter-server -Djava.rmi.server.hostname=10.132.91.141 (Slave 1)
./jmeter-server -Djava.rmi.server.hostname=10.132.88.44 (Slave 2)
I tried to trigger test with the following command on Master node
jmeter -n -Jthreads=10 -Jrampup=30 -Jduration=60 -Jiterations=-1 -t sampletest.jmx -R 10.132.91.141,10.132.88.44 -Djava.rmi.server.hostname=10.132.89.172 -Dclient.rmi.localport=1099
I get the following issues.
After it logs "Starting distributed test with remote engines" on master noder, it takes about 10 or so mintues to log "Starting the test on host 10.132.91.141" and also there is lot of delay in start triggering the requests on Slave 1 and lot more delay to start on Slave 2.
On the Slave nodes (jmet-server.log), I see Connection refused errors to Master node. java.rmi.ConnectException: Connection refused to host: 10.132.89.172
Memory usgage on Slave nodes keep shooting up and results in OutOfMemory errors even after changing HEAP to xmx10g.
Master node is stuck at this step and never comes back.
Waiting for possible Shutdown/StopTestNow/HeapDump/ThreadDump message on port 4445
Appreciate any input to resolve the issues.
Do not run jmeter-server
on master machine.
You can follow these steps below:
Add your slave machine IP's (10.132.91.141, 10.132.88.44
) to the jmeter.properties
file.
remote_hosts= 10.132.91.141, 10.132.88.4
Add the following to each slave machines jmeter-server
file:
RMI_HOST_DEF=-Djava.rmi.server.hostname= ip_of_jmeter_server
Start jmeter-server from those two slave machines
./jmeter-server
Run your test from the master machine as
jmeter -n -Gthreads=10 -Grampup=30 -Gduration=60 -Giterations=-1 -t sampletest.jmx -r
Use -G
flag for Jmeter property to be sent to all remote servers. Check the documentation on Overriding Properties Via The Command Line
Double-check that you have fulfilled all the prerequisite to perform Distributed test:
All machines(Master & Slaves) are in the same subnet.
The firewall is disabled for all machines.
JMeter and JDK versions are the same for all machines.