0
votes

I have a jmeter test plan that is running in a non gui mode on linux to test a server. I want to pause the jmeter test plan for some time to carry some maintenance on server and want to resume the test plan from where it got paused.

I don't know when to stop the test plan before hand, so i can't use timers to code in jmeter

Is there a pause button on jmeter GUI and NON GUI mode to pause the test plan

2

2 Answers

1
votes
  1. Linux solution. If you're running Linux you can use kill command like:

    • kill -STOP 1234 - pause JMeter
    • kill - CONT 1234 - resume JMeter

      replace 1234 with the associated Java process ID

  2. JMeter solution. You can add Constant Throughput Timer to your test plan and set the desired throughput in "requests per minute" using __P() function. When you need to suspend JMeter - you can set the desired throughput to 0 via Beanshell Server. Check out How to Change JMeter´s Load During Runtime article for comprehensive information if needed.

0
votes

It is not possible to pause Jmeter execution.Thread groups are configured in such a way that it wind through requests and execute test plans fully. The only way to make changes in server is to stop the test, change what you need to and then execute the test again from the beginning.

Also, the test will not make any sense when you resume it after updates in server. Because mostly when updates are done on servers, apache will be restarted for safer side. That means the requests you sent previously is not anymore in the queue. So, even if there is a pause button in JMETER, the test after resume would be the same as that of a new test.

Best practice to do: Run test completely before server update. Take out the results. Run test after server update. Take out the results. Then compare the results.