Browse Source

turn off check swap if needed

tags/mcp0.5
vmikes 8 years ago
parent
commit
a63f4053f3
2 changed files with 10 additions and 4 deletions
  1. +9
    -3
      linux/map.jinja
  2. +1
    -1
      linux/meta/sensu.yml

+ 9
- 3
linux/map.jinja View File

@@ -124,7 +124,9 @@
{% set storage = salt['grains.filter_by']({
'Arch': {
'mount': {},
'swap': {},
'swap': {
'enabled': True,
},
'lvm': {},
'multipath': {
'enabled': False,
@@ -134,7 +136,9 @@
},
'Debian': {
'mount': {},
'swap': {},
'swap': {
'enabled': True,
},
'lvm': {},
'multipath': {
'enabled': False,
@@ -145,7 +149,9 @@
},
'RedHat': {
'mount': {},
'swap': {},
'swap': {
'enabled': True,
},
'lvm': {},
'multipath': {
'enabled': False,

+ 1
- 1
linux/meta/sensu.yml View File

@@ -18,7 +18,7 @@ check:
occurrences: 1
subscribers:
- local-linux-system
{%- if storage.swap is defined %}
{%- if storage.swap.enabled %}
local_linux_storage_swap_usage_{{ system.name|replace('.', '-') }}-{{ system.domain|replace('.', '-') }}:
command: "PATH=$PATH:/usr/lib64/nagios/plugins:/usr/lib/nagios/plugins check_swap -a -w 50% -c 20%"
interval: 60

Loading…
Cancel
Save