diff --git a/check_syslog b/check_syslog index 67f9c5f22414dfec7486c59c7d48555982161b3e..2716ce47588a0eb15889d8cf9ff203dfa9fe50ac 100755 --- a/check_syslog +++ b/check_syslog @@ -12,6 +12,11 @@ import time import os import errno +CANON = { + 'kraiklyn.mgmt': 'kraiklyn', + 'inservitus': 'studsvik', + } + def filename(y, m, d, host): return "/misc/syslogs/%04d-%02d/%04d-%02d-%02d/%s" % ( y, m, y, m, d, host) @@ -32,6 +37,7 @@ def find_newest_file(hostname): return None, None def check_host(hostname): + hostname = CANON.get(hostname, hostname) fn, statval = find_newest_file(hostname) if fn is None: print "CRITICAL - no activity within the last 14 days"