-
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
[receiver/hostmetrics] change the log level when filesystem fails to scrape patition #18236
Comments
Pinging code owners:
See Adding Labels via Comments if you do not have permissions to add labels yourself. |
@dloucasfx for first option, it looks like this is now supported. Check out opentelemetry-collector-contrib/receiver/hostmetricsreceiver/internal/scraper/diskscraper/config.go Line 32 in 7b88749
|
Did you also mention it would be good to offer a way to configure a zap.Filter on the logger? |
The link is for the disk scraper, this issue is in the filesystem scraper; Regardless, the Filesystem has filtering options, but the filtering happens after all the filesystem info is collected, ie: after the error is logged |
Oh yeah, when I was looking into this issue I was hoping that our logging support the zapfilter https://pkg.go.dev/moul.io/zapfilter where user can filter based on log messages. This is definitely an enhancement, but if we have it in place, we can workaround this bug. |
Taking a look into this issue now. |
Merged in a small fix, should be available in v0.73.0. |
I'm having a very similar issue with version 0.95.0 of the collector agent on Windows servers where the disks are locked by SIOS. Our Windows Application event logs are flooded with Errors from the agent when hitting locked disks. The disks are only active on the SQL server node where the roles are currently assigned to and if we have to failover they will migrate. This is a dynamic setup and we do need metrics from those disks whenever they are active on any of the nodes in the cluster. Should I open a new bug ticket for this? I'm not completely familiar with the process but can definitely use this ticket as my guide along with the documentation for contributing.
Quick edit here I did go ahead and try 0.110.0 and I am having the same issue. I'm not sure how Logz.io repackages the collector though so I was only doing this as a quick test. |
Component(s)
receiver/hostmetrics filesystem scraper
What happened?
Description
This is a gray area between a bug / improvement, but due to the large number of "unnecessary" error messages in the logs, I am filing it as a bug.
After this change a0abefc the filesystem scraper is logging every partition that fails to be scraped, will add an error message through the
errors.AddPartial
.From the first look, this is the right approach, however, some partitions (example: windows partitions that are bitlocker encrypted, or any partition that we don't have access to), are known to fail, problem is that user has no way to filter them out before they get scraped and they will end up with error messages polluting their logs.
Steps to Reproduce
Run the hostmerics/filesystem receiver/scraper on system with non-acessible partition, example: windows with BitLocker Drive
Expected Result
No errors should be logged, only when agent is set on debug.
Or, provide a way to filter out those partitions
Actual Result
The text was updated successfully, but these errors were encountered: