OutOfMemoryError in JMeter

纵饮孤独 提交于 2020-01-14 12:24:12

问题


In JMeter I am getting this error.

jmeter.JMeter: Uncaught exception:  java.lang.OutOfMemoryError: Java heap space

Please let me know how to resolve.


回答1:


Increase the JMeter heap memory

  1. Within your explorer find where you installed JMeter
  2. Open up the bin directory.
  3. Find the JMeter.bat file and open it with a text editor
  4. Find the following set HEAP

    You can set this HEAP value to whatever you like, in this example I've said allocate 2 GB of memory from the start and throughout the test run: set HEAP=-Xms2048m -Xmx2048m




回答2:


Have you considered adding another load generator? Even if you get to 80% of your pool you are going to have testbed influences on your result set. This, by the way, is tool independent.

Recommended best course is at least three load gens. Two for primary load and one for a control set of a single business process of each type. If all degrade together then you know with high certainty that you have a common issue, app degradation. If your primary degrade but not your control then you have overloaded generators. It's best you catch them rather than using bad data to make a decision on scalability that could result in chasing engineering ghosts in your code.



来源:https://stackoverflow.com/questions/26751940/outofmemoryerror-in-jmeter

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!