Description
Hi,
I run few instances of logstash, since upgrade to 2.2.2 i started to notice permanent crashes caused by OOM errors. Bigger heap only increase interval between OOMs. I checked heap dump and found excessive amount of org.apache.http.config.Registry objects.
Out of 3GB I had 887000 Registries taking 1.4GB of memory.
I started to monitory tenured memory utilization and amount of Registries object instances on the heap for each logstash instance.
Number of Registry objects 1GB heap (jmap -gchisto)
Tenured memory utilization 1GB heap (jstat -gcutil)
Drops from 85% to few percent indicate watchdog killed process as there was no point to waste CPU due to CMS cycles as memory won't be recycled.
You may notice one series of data on those screenshots that looks pretty fine, that's instance with sniffing set to false, all others had sniffing => true
Once disabled sniffing on all instances the problem is gone.
Disabled Sniffing: Number of Registry objects 1GB heap (jmap -gchisto)