jmeter-heap设置

问题:启动或高压测试过程如果内存溢出的话,会出现这个提示:java.lang.OutOfMemoryError: Java heap space:意思就是堆内存溢出,不够用了。

解决方法:windows下在jmeter.bat文件里面修改,:
version4.0:
if not defined HEAP (
rem See the unix startup file for the rationale of the following parameters,
rem including some tuning recommendations
set HEAP=-Xms1g -Xmx1g -XX:MaxMetaspaceSize=256m
)
Xms1g _初始值 ,一般不能大于物理内存1/2
-Xmx1g 最大值
1个线程=1M,根据要测并发数来推测大小
转载于:https://www.cnblogs.com/imyalost/p/7901064.html

猜你喜欢

转载自blog.csdn.net/weixin_43533308/article/details/105624217