-
Notifications
You must be signed in to change notification settings - Fork 152
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
grok_exporter v 0.2.6 resident memory rising #55
Comments
This is a bug. Will investigate where this comes from. Thanks for reporting. |
Found a memory leak in |
I'm using summary and gauge metrics. Do those call |
I released a bugfix release 0.2.7. Could you check if this solves the issue? |
There's a buffer in |
Thanks for the data. If I see the colors correctly the One thing you could do is to figure out why processing takes so long. Sometimes there is a single regular expression taking most of the processing time. The metric Could you run that query to see if there is any metric that takes significantly longer than the others? Maybe we can optimize the regular expression for that metric to make processing faster. |
I can take out The metric is The frequency of this log is quite high, any chance this can be optimized? |
It doesn't look too bad. Some things you can try:
|
An optional flag like |
I didn't add a buffer limit so far because dropping log lines makes On the other hand, if you have to restart Meanwhile I added a log message, so if log messages are written faster than they are processed |
Thanks for taking a look. I am not really parsing the log messages from |
I started implementing a limit for the number of lines in the line buffer. Specifying a number of lines is not as convenient as specifying a max amount of memory, but it's easier to implement and better than running out of memory. I will comment here when it's done. |
I implemented a config option for the input:
type: file
path: /var/log/messages
max_lines_in_buffer: 100000 The example would drop the buffer if it reaches 100000 log lines. This is not good, because you loose 100000 log lines in monitoring, but it's better than running out of memory and crashing. You need to build |
Thanks! Does the release script still need go version < 1.12? If so, I'll to wait for the release since I'm using go version 1.12 and haven't figured out using 2 versions of go simultaneously in my environment. |
The release script works with go 1.12. |
I started to see a few counters are not getting incremented even though |
@raokrutarth could you provide an example of a log line and the counter? I can have a look why it's not incremented. |
re-posted comment on #58. memory issues are resolved with |
I have a fairly frequently updated log file that I am using grok exporter to count specific log entries. I see that the resident memory usage by the exporter is quite high and growing. This happens 3/4 of the time in my env.
Graph:
The config is:
The text was updated successfully, but these errors were encountered: