Tighten rabbitmq thresholds and page_admins
(imported from commit 373014bf75346286b55b0ea7d370b21de49ffa33)
This commit is contained in:
parent
3e2c0c7a8a
commit
a1b74e9fd7
|
@ -5,13 +5,13 @@ import subprocess
|
||||||
import re
|
import re
|
||||||
import time
|
import time
|
||||||
|
|
||||||
from os import path
|
from os import path, environ
|
||||||
|
|
||||||
sys.path.append(path.join(path.dirname(__file__), '../tools'))
|
sys.path.append(path.join(path.dirname(__file__), '../tools'))
|
||||||
from humbug_tools import check_output
|
from humbug_tools import check_output
|
||||||
|
|
||||||
WARN_THRESHOLD = 100
|
WARN_THRESHOLD = 50
|
||||||
CRIT_THRESHOLD = 200
|
CRIT_THRESHOLD = 100
|
||||||
|
|
||||||
states = {
|
states = {
|
||||||
0: "OK",
|
0: "OK",
|
||||||
|
@ -27,6 +27,9 @@ status = 0
|
||||||
max_count = 0
|
max_count = 0
|
||||||
warn_queues = []
|
warn_queues = []
|
||||||
|
|
||||||
|
if not environ['USER'] in ['root', 'rabbitmq']:
|
||||||
|
print "This script must be run as the root or rabbitmq user"
|
||||||
|
|
||||||
for line in output.split("\n"):
|
for line in output.split("\n"):
|
||||||
line = line.strip()
|
line = line.strip()
|
||||||
m = re.match(line)
|
m = re.match(line)
|
||||||
|
|
Loading…
Reference in a new issue