diff --git a/checks/cisco_wlc_temp b/checks/cisco_wlc_temp deleted file mode 100644 index db585e9403a3d02d7c7e995d56d2f264c9300120..0000000000000000000000000000000000000000 --- a/checks/cisco_wlc_temp +++ /dev/null @@ -1,82 +0,0 @@ -#!/usr/bin/python -# -*- encoding: utf-8; py-indent-offset: 4 -*- -# -# created by Th.L.: -# Monitors Cisco WLC temperatur sensors -# tested with WLC2504 -# 02.07.2016: fixed crit/warn to >= -# 14.09.2018: workaround for wrong data from Mobility Express Controller --> removed -# -# -# sample info -# -# [[u'1', u'38', u'0', u'65']] -# - -cisco_wlc_temp_default_levels = (50, 60) - - -def inventory_cisco_wlc_temp(info): - environment, temperature, lowlimit, highlimit = info[0] - cisco_wlc_temp_levels = cisco_wlc_temp_default_levels - highlimit = int(highlimit) - lowlimit = int(lowlimit) - - if cisco_wlc_temp_levels[1] >= highlimit >= 15: - cisco_wlc_temp_levels = (highlimit - 15, highlimit - 5) # stay on the save side - - return [(None, cisco_wlc_temp_levels)] - - -def check_cisco_wlc_temp(item, params, info): - state = 0 - infotext = '' - longoutput = '' - warn, crit = params - environment, temperature, lowlimit, highlimit = info[0] - - environment = int(environment) - temperature = int(temperature) - - # workarounfd for Mobility Express controller, announces a temperature of 5000 - # if temperature > 1000: - # temperature = temperature/100 - - lowlimit = int(lowlimit) - highlimit = int(highlimit) - - infotext += u'%d\xB0C' % temperature - - longoutput += u'\nlimits: low/high %d\xB0C/%d\xB0C' % (lowlimit, highlimit ) - - if environment == 1: - longoutput += u'\ncommercial operating environment (0\xB0C to 40\xB0C)' - elif environment == 2: - longoutput += u'\nindustrial operating environment (-10\xB0C to 70\xB0C)' - - perfdata = [('celsius', temperature, warn, crit, lowlimit, highlimit)] - - if temperature >= crit: - state = 2 - infotext += ' (>= %d)' % crit - elif temperature >= warn: - state = 1 - infotext += ' (>= %d)' % warn - - return state, infotext + longoutput, perfdata - - -check_info['cisco_wlc_temp'] = { - 'check_function' : check_cisco_wlc_temp, - 'inventory_function' : inventory_cisco_wlc_temp, - 'service_description': 'Environment: Internal Temperature', - 'has_perfdata' : True, - 'group' : 'cisco_wlc_temp', - 'snmp_scan_function': lambda oid: oid('.1.3.6.1.2.1.1.1.0') == 'Cisco Controller', - 'snmp_info' : ('.1.3.6.1.4.1.14179.2.3.1', [ # AIRESPACE-WIRELESS-MIB::bsnGlobalDot11Config - '12', # bsnOperatingTemperatureEnvironment - '13', # bsnSensorTemperature (Current Internal Temperature of the unit in Centigrade) - '14', # bsnTemperatureAlarmLowLimit - '15', # bsnTemperatureAlarmHighLimit - ]), -}