Cherry-pick #24334 to 7.x: Refactor use of system.hostfs to fix cgroup metrics#24951
Closed
fearful-symmetry wants to merge 1 commit intoelastic:7.xfrom
Closed
Cherry-pick #24334 to 7.x: Refactor use of system.hostfs to fix cgroup metrics#24951fearful-symmetry wants to merge 1 commit intoelastic:7.xfrom
fearful-symmetry wants to merge 1 commit intoelastic:7.xfrom
Conversation
* refactor use of system.hostfs to fix cgroup metrics * add changelog * remove comment * add cfgwarn * move changelog * shift around CLI config location and rep warning * add comment about system.hostfs usage * update docs * capitalization * fix grammar, add conditional * change docs phrasing (cherry picked from commit c70fe5c)
Contributor
|
Pinging @elastic/integrations (Team:Integrations) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Cherry-pick of PR #24334 to 7.x branch. Original message:
What does this PR do?
This is a fix for #23267, wherein we weren't passing a
hostfsto the metricbeat self-monitor code. In order to fix this in a somewhat clean way, I ended up migrating all of the hostfs handling tolibbeat/path, and out of the system module entirely. This is a bit of a weird edge case forlibbeat/path, so just tell me if this should be done somewhat differently.Why is it important?
As explained in the linked issue, this is causing problems for users setting
hostfs.Checklist
CHANGELOG.next.asciidocorCHANGELOG-developer.next.asciidoc.How to test this PR locally
socket,process,entropyanddiskioare working correctly.system.hostfssetting, such as in a container, like this:Insure that the above metricsets are still working, and that no errors like
instance/metrics.go:285 error getting group status: open /proc/33861/cgroup: no such file or directoryappear.Related issues
Logs
Tested, it looks like we're properly reporting cgroup metrics inside a docker container: