Reputation: 41
I tried to increase the heap size for Jmeter in while executing the .jmx file using "JVM_ARGS="-Xms1024m -Xmx1024m" jmeter -t test.jmx [etc.]" command. however, it doesn't seem to work.
Upvotes: 3
Views: 9602
Reputation: 1017
If you need to set a different amount of ram in each execution, you can export it with the env var HEAP
and then run your jmeter script.
export HEAP="-Xms3g -Xmx3g -XX:MaxMetaspaceSize=1g"
jmeter ...
Upvotes: 0
Reputation: 1991
Create setenv.sh
in JMETER_HOME/bin
: touch ${JMETER_HOME}/bin/setenv.sh
Edit file vi setenv.sh
To set maximum 8Gb,for example, add line: HEAP="-Xms512m -Xmx8g"
Upvotes: 1
Reputation: 2511
On my Ubuntu , I modified the jmeter script launcher like this: (heap's line)
# system's memory availablity:
HEAP="-Xms1024m -Xmx2048m"
At the bottom of script , you can see :
ARGS="$SERVER $DUMP $HEAP $NEW $SURVIVOR $TENURING $EVACUATION $RMIGC $PERM"
java $ARGS $JVM_ARGS -jar "`dirname "$0"`/ApacheJMeter.jar" "$@"
Upvotes: 1