Versions: 2.9.0
I want to setup a monitor that will essentially run this query /_nodes/stats/fs?pretty
I want to be able to display storage usage per node in dashboards as well alert on it. How can I do this? Do I parse ctx.results?
Also, can I write the results to an index which be accessed by grafana?
Thanks in advance
Maybe you can try to use prometheus exporter for OpenSearch to expose all of the metrics, and then use Prometheus + Grafana to store, display the metrics and setup monitors. If you want to store all of the metrics data into your OpenSearch cluster and then display the metrics in OpenSearch-Dashboards and setup monitor by alerting plugin in OpenSearch, you can try to use Logstash or other tools to pull the metrics from the prometheus exporter and then write them to OpenSearch index, there’s a Logstash plugin can do that.
Isn’t there a native way of doing things? I read that prometheus exporter is too heavy and affects node performance?
@gaobinlong I have installed the prometheus exporter. What role/cluster permissions I would need to assign the user executing the pull request _prometheus/metrics against opensearch from prometheus?
The permission is cluster:monitor/prometheus/metrics
, you can see it here: NodePrometheusMetricsAction. If you don’t want to use the exporter plugin for OpenSearch, you can consider using this exporter for elasticsearch which can run independently as a single process, but there maybe some compatibility issue.
1 Like