Native memory allocation (malloc) failed to allocate 32756 bytes for ChunkPool::allocate

Praveen Rao Chavan.G picture Praveen Rao Chavan.G · Jun 28, 2018 · Viewed 9.7k times · Source

We have a JMeter test which stops in between giving the following error message

enter image description here

It runs fine when I run the tests with a load of 100,200 and 300 Users

I found one question jmeter test failed with out of memory error but that didn't help to solve the issue.

Have tried running this on machines with 12 GB RAM and also with a 16 GB RAM.

What could be the possible reason for it to behave so?

also tried to run on non-GUI mode even there the test stops.

Non GUI mode

Answer

Dmitri T picture Dmitri T · Jun 28, 2018
  1. Don't run your test in GUI mode, as per first line of your terminal output you should be using non-GUI mode for running your tests. GUI mode is for tests development or debugging only.
  2. Make sure to use 64-bit Java JDK or Server JRE, you need to choose Windows x64 option
  3. Increase your JVM Heap size by amending HEAP environment variable like:

    set HEAP=4G && jmeter.bat -n -t test.jmx -l result.jtl
    
  4. Make sure to follow JMeter Best Practices and recommendations from 9 Easy Solutions for a JMeter Load Test “Out of Memory” Failure article