-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
Clarify rotation expectation for containerd logs in filelogreciever #35777
Comments
Pinging code owners:
See Adding Labels via Comments if you do not have permissions to add labels yourself. |
You can read about how the receiver is designed to handle log rotation here. In short, it tries to make no assumptions except that files are append-only. |
Thank you @djaglowski I was confused because the debug logs would always show the original log name, I had thought it might change to the rotated name, that was a bad assumption. Indeed it is working as expected and my problem ended up being CPU throttling. |
Seems like a reasonable assumption to me and something we could likely fix. |
Component(s)
receiver/filelog
Describe the issue you're reporting
The example in container parser has an include of
.../*.log
which matches the kubernetes example.I am using containerd, and the log names that kubelet creates are as follows.
Do I need to include the
0.log.20241010-132438
file in the fileloginclude
section? It seems to follow the log when it's rotated, but I'm having a small loss of logs and I think it might be having an issue since the new name is not in includes. According tootelcol_fileconsumer_reading_files
metric there are many files being read at a time so I think not including it is correct.It's very difficult to tell from the documentation what is the correct action here to include or not though so I was hoping you might help clarify it for me.
If it should be included this is the config.
The text was updated successfully, but these errors were encountered: