diff options
author | Jesse Luehrs <doy@tozt.net> | 2021-07-07 10:20:16 -0400 |
---|---|---|
committer | Jesse Luehrs <doy@tozt.net> | 2021-07-07 10:22:30 -0400 |
commit | 6c61d5d5264805d97190c2a1f5ab2ce04b4ccdd3 (patch) | |
tree | 992078e21fe37dbe1a103448ba06ed9ea60d5993 /modules/tozt/files/kapacitor/cpu.tick | |
parent | 0b481c9d28f1de0c1a6e9ed232b15c5b53979a76 (diff) | |
download | puppet-tozt-6c61d5d5264805d97190c2a1f5ab2ce04b4ccdd3.tar.gz puppet-tozt-6c61d5d5264805d97190c2a1f5ab2ce04b4ccdd3.zip |
remove some no longer used files
Diffstat (limited to 'modules/tozt/files/kapacitor/cpu.tick')
-rw-r--r-- | modules/tozt/files/kapacitor/cpu.tick | 32 |
1 files changed, 0 insertions, 32 deletions
diff --git a/modules/tozt/files/kapacitor/cpu.tick b/modules/tozt/files/kapacitor/cpu.tick deleted file mode 100644 index cc7eb14..0000000 --- a/modules/tozt/files/kapacitor/cpu.tick +++ /dev/null @@ -1,32 +0,0 @@ -dbrp "telegraf"."autogen" - -var message = ''' -{{- if eq .Level "OK" -}} -{{ index .Tags "host" }} is no longer using excessive CPU -{{- else -}} -{{ index .Tags "host" }} is using excessive CPU -{{- end -}} -''' - -var details = ''' -{{- if eq .Level "OK" -}} -{{ index .Tags "host" }} is now only using {{ index .Fields "mean" }}% CPU -{{- else -}} -{{ index .Tags "host" }} has used an average of {{ index .Fields "mean" }}% CPU for the last 10 minutes -{{- end -}} -''' - -stream -|from() - .measurement('cpu') - .groupBy('host') - .where(lambda: "cpu" == 'cpu-total') -|eval(lambda: 100.0 - "usage_idle") - .as('usage') -|window() - .period(1h) -|mean('usage') -|alert() - .crit(lambda: "mean" > 90) - .message(message) - .details(details) |