Bug 51916 - OutOfMemoryError remote testing with HTTPClient HC4 and JMeter 2.5
Summary: OutOfMemoryError remote testing with HTTPClient HC4 and JMeter 2.5
Status: RESOLVED FIXED
Alias: None
Product: JMeter
Classification: Unclassified
Component: HTTP (show other bugs)
Version: 2.5
Hardware: All All
: P2 critical (vote)
Target Milestone: ---
Assignee: JMeter issues mailing list
URL:
Keywords:
Depends on: 51752 51863
Blocks:
  Show dependency tree
 
Reported: 2011-09-29 13:12 UTC by Philippe Mouawad
Modified: 2011-09-30 10:52 UTC (History)
1 user (show)



Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Philippe Mouawad 2011-09-29 13:12:03 UTC
Hi, I'm trying to run a fairly simple test plan in distributed mode and
experiencing some interesting memory consumption issues which I hope someone
can shed some light on..

The problem is regardless of how many threads I use, each of the slave
servers sees growing memory usage until they eventually run out of memory
and the jmeter-server process dies with this error:
java.lang.OutOfMemoryError: Java heap space

I am very confused by this behaviour as my understanding of the slave mode
jmeter-server is that it should be passing all data back to the master and
the JVM GCs should be taking care of the memory, sadly this is not the case.

Regardless of how many threads I use, with or without a constant timer etc..
the memory usage of the java process on each of the slaves ramps up...

Config:
1 x Master Server - Linux, GUI mode (CentOS x64)
3 x Slave Server - Linux (CentOS x64)

Test plan:
- 10,000 loops @ 5 threads
- One thread group
- Constant Timer (500ms)
- 15 HTTP Requests (using HTTP client, non ssl.)
- One listener (Aggregate report)

Any ideas?

Things I've tried:
- Simple test plans.
- Upping heap size on master + slaves to 1024
- Batch mode processing for results
- Removing all listeners



- No other test elements in use other than what I listed in the OP.
- Jmeter version: 2.5

I've tried removing all the listeners and running from NON-GUI mode with -l
from the master, this is the command I used: ./jmeter -n -r -t cli-test.jmx
-l example-log

Sadly this has made no difference and the slaves still escalate memory usage
until they eventually run out and jmeter-server OOM kills itself with
java.lang.OutOfMemoryError: Java heap space

There's something not right here, I suspect either a memory leak or failing
GC, any ideas?

nb. I am using the latest version of Java on CentOS:
java version "1.6.0_27"
Java(TM) SE Runtime Environment (build 1.6.0_27-b07)
Java HotSpot(TM) Server VM (build 20.2-b06, mixed mode)
Comment 1 Philippe Mouawad 2011-09-30 10:52:03 UTC
Issue was due to a bug in HC4 implementation fixed in:
- 51863
- Fix HttpClient 4 sampler so it reuses HttpClient instances and connections where possible

Message from Poox:
I can confirm that RC3 fixes my problem and I now have stable memory usage
having run the same .jmx overnight for confirmation.

See:
http://jmeter.512774.n5.nabble.com/Distributed-testing-Memory-usage-td4849000.html#a4856496


Workaround in 2.5 is to use HttpClient 3
Fix is in 2.5.1

Regards
Philippe Mouawad