feat(inputs.temp): Add setting to force thermal-zones gathering on linux#18906
Conversation
srebhan
left a comment
There was a problem hiding this comment.
Thanks for your contribution @01110111000001! Can we please split the PR into two, a first PR fixing the blocking read (i.e. marking it as a fix) and a second PR adding the option to force reading from thermal zones?
058da6d to
41fa053
Compare
|
Yes! See #18913 for the PR implementing the fix. |
|
Download PR build artifacts for linux_amd64.tar.gz, darwin_arm64.tar.gz, and windows_amd64.zip. 📦 Click here to get additional PR build artifactsArtifact URLs |
srebhan
left a comment
There was a problem hiding this comment.
Nice! Thanks @01110111000001 for your contribution!
skartikey
left a comment
There was a problem hiding this comment.
@01110111000001 Thanks for the contribution!
Summary
When the hardware device is sleeping, the temp input plugin completely hangs waiting for the os.ReadFile call to return.moved to its own PR, see fix(input.temp): Ignore EAGAIN on unavailable thermal-zones #18913The EAGAIN returned by the kernel is handled internally by os.ReadFile and the function waits for the file to become available.
-> Use the non-blocking syscall function to read the files and silently ignoring unavailable thermal-zones.
Adding a parameter to force the gathering of the thermal-zones temperatures. Some systems combine both hwmon and thermal-zones. Current implemenentation ignores thermal-zones when some hwmon exist.
Some comments/potential issues
technically these are two distinct features, should I open 2 PRs?the fix moved to its own PR, see fix(input.temp): Ignore EAGAIN on unavailable thermal-zones #18913Looking forward to your feedback and your thoughts on the potential issues.
Thanks for your great work on this tool!
Checklist
Related issues
partially resolves #18899
related to #18913