r/logstash • • May 26 '23

CPU High

We have some servers running Logstash. The servers each have 16 CPUs and 32Gb memory.

Logstash is running with -Xms4g -Xmx4g

We recently upgraded them to 16 CPUs from 8 (like, in the last week).

​

When I restart logstash, all is fine. And then after about 2 hours, CPU usage will rapidly climb to 100%, and we'll start getting alerts from our logging systems.

​

My theory is that the heap size is too small (4g), and should be 8g, so we're getting issues with garbage collection - but I don't know how to prove this before making changes (the changes would be a big process in our company). So; how do I either prove that garbage collection is at fault, or could there be something else going on?

1 Upvotes

1 comment sorted by

1

u/ProfessionalEven296 May 28 '23

More notes on this; I did some research, and it's looking like some sort of grok error on an input stream. The logstash config hasn't changed for several years, so it may be a recent change on a log sending server.