metricbeat filesystem metrics not being output to prometheus
Closed this issue · 5 comments
In my metricbeat console output I have this:
"system": {
"filesystem": {
"type": "fuse.glusterfs",
"device_name": "10.154.131.242:vol_f19380703ea925da14813fcfa05fa331",
"available": 10524708864,
"mount_point": "/mnt",
"free_files": 5225819,
"used": {
"pct": 0.0189,
"bytes": 202223616
},
"total": 10726932480,
"files": 5242880,
"free": 10524708864
}
},
But in metric output from beat-exporter I only have:
metricbeat_metricbeat_system_filesystem system.filesystem
metricbeat_metricbeat_system_filesystem counter
and event failures and success.. Nothing about the above stats - which is what I actually need :(
from a quick glance at the GO code (I've never written GO before :) - it seems it would need to add a filesystem struct like this memstat one: https://github.com/trustpilot/beat-exporter/blob/master/collector/beat.go#L33
And then adding sections for parsing each counter like that : https://github.com/trustpilot/beat-exporter/blob/master/collector/beat.go#L109
But only for metricbeat with system collector enabled ofcourse.. (or does it just ignore if its not there)
?
or perhaps more like this: https://github.com/trustpilot/beat-exporter/blob/master/collector/beat.go#L89 - setting labels for instance and device_name and counter name simply being the used.pct and used.bytes total, files, free and free_files (which I assume is actually inodes free :)
Am I on the right track here? then I can try it out :)
and it should be a gauge - not a counter I think
I just investigated a bit, and can see that filesystem stats is not exposed via http interface - and it seems from discussion on elastic forum that they never will be (they're not interested in metricbeat being usable for anything other than their stack :(