summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--collectors/freeipmi.plugin/freeipmi_plugin.c15
-rw-r--r--health/Makefile.am1
-rw-r--r--health/health.d/plugin.conf11
3 files changed, 27 insertions, 0 deletions
diff --git a/collectors/freeipmi.plugin/freeipmi_plugin.c b/collectors/freeipmi.plugin/freeipmi_plugin.c
index 98538e81b8..a2251891ae 100644
--- a/collectors/freeipmi.plugin/freeipmi_plugin.c
+++ b/collectors/freeipmi.plugin/freeipmi_plugin.c
@@ -1833,6 +1833,21 @@ int main (int argc, char **argv) {
for(iteration = 0; 1 ; iteration++) {
usec_t dt = heartbeat_next(&hb, step);
+ if (iteration) {
+ if (iteration == 1) {
+ fprintf(
+ stdout,
+ "CHART netdata.freeipmi_availability_status '' 'Plugin availability status' 'status' plugins netdata.plugin_availability_status line 146000 %d\n"
+ "DIMENSION available '' absolute 1 1\n",
+ netdata_update_every);
+ }
+ fprintf(
+ stdout,
+ "BEGIN netdata.freeipmi_availability_status\n"
+ "SET available = 1\n"
+ "END\n");
+ }
+
if(debug && iteration)
fprintf(stderr, "freeipmi.plugin: iteration %zu, dt %llu usec, sensors collected %zu, sensors sent to netdata %zu \n"
, iteration
diff --git a/health/Makefile.am b/health/Makefile.am
index ea1b6e961e..0ef55c75e2 100644
--- a/health/Makefile.am
+++ b/health/Makefile.am
@@ -69,6 +69,7 @@ dist_healthconfig_DATA = \
health.d/nvme.conf \
health.d/nut.conf \
health.d/pihole.conf \
+ health.d/plugin.conf \
health.d/ping.conf \
health.d/postgres.conf \
health.d/portcheck.conf \
diff --git a/health/health.d/plugin.conf b/health/health.d/plugin.conf
new file mode 100644
index 0000000000..0a891db792
--- /dev/null
+++ b/health/health.d/plugin.conf
@@ -0,0 +1,11 @@
+ template: plugin_availability_status
+ on: netdata.plugin_availability_status
+ class: Errors
+ type: Netdata
+ calc: $now - $last_collected_t
+ units: seconds ago
+ every: 10s
+ warn: $this > (($status >= $WARNING) ? ($update_every) : (20 * $update_every))
+ delay: down 5m multiplier 1.5 max 1h
+ info: the amount of time that ${label:_collect_plugin} did not report its availability status
+ to: sysadmin