From: Costa Tsaousis (ktsaou) Date: Sat, 27 Aug 2016 09:03:31 +0000 (+0300) Subject: memcached alarms #810 X-Git-Tag: v1.3.0~4^2~7 X-Git-Url: https://arthur.barton.de/gitweb/?a=commitdiff_plain;h=90f07ee6353504ab93788f39e9ec432053887747;p=netdata.git memcached alarms #810 --- diff --git a/conf.d/health.d/disks.conf b/conf.d/health.d/disks.conf index d1603104..7cfcad27 100644 --- a/conf.d/health.d/disks.conf +++ b/conf.d/health.d/disks.conf @@ -27,7 +27,7 @@ template: disk_full_percent template: disk_fill_rate on: disk.space lookup: max -1s at -30m unaligned of avail - calc: ($this - $avail) / (30 * 60) + calc: ($this - $avail) / ($now - $after) every: 15s diff --git a/conf.d/health.d/memcached.conf b/conf.d/health.d/memcached.conf index 9e795b15..604102e3 100644 --- a/conf.d/health.d/memcached.conf +++ b/conf.d/health.d/memcached.conf @@ -8,3 +8,34 @@ template: memcached_last_collected_secs warn: $this > ( 5 * $update_every) crit: $this > (10 * $update_every) + + +# detect if memcached cache is full + +template: cache_full_pcent + on: memcached.cache + calc: $used * 100 / ($used + $available) + every: 10s + warn: $this > 80 + crit: $this > 90 + + + +# find the rate memcached cache is filling + +template: cache_fill_rate + on: memcached.cache + lookup: max -1s at -30m unaligned of available + calc: ($this - $available) / ($now - $after) + every: 15s + + + +# find the hours remaining until memcached cache is full + +template: cache_full_after_hours + on: memcached.cache + calc: $available / $memcached_cache_fill_rate / 3600 + every: 10s + warn: $this > 0 and $this < 48 + crit: $this > 0 and $this < 24 diff --git a/conf.d/health.d/swap.conf b/conf.d/health.d/swap.conf index 64fd9b60..39e6a523 100644 --- a/conf.d/health.d/swap.conf +++ b/conf.d/health.d/swap.conf @@ -1,7 +1,7 @@ alarm: 30min_pcent_of_ram_swapped_out on: system.swapio - lookup: sum -30m unaligned of out + lookup: sum -30m unaligned absolute of out # we have to convert KB to MB by dividing $this (i.e. the result of the lookup) with 1024 calc: $this / 1024 * 100 / ( $system.ram.used + $system.ram.cached + $system.ram.free ) every: 1m