Module: check_mk
Branch: master
Commit: 5e438501650fe28f65505ab7070fc5ac3673e48d
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=5e438501650fe2…
Author: Simon Betz <si(a)mathias-kettner.de>
Date: Wed Feb 10 16:45:10 2016 +0100
#2979 aruba_wlc_aps: new inventory plugin for Aruba Networks WLAN Controller which
displays name, group name, model, serial number and system location of all access points
of this WLC
---
.werks/2979 | 9 +++++
ChangeLog | 1 +
inventory/aruba_wlc_aps | 76 ++++++++++++++++++++++++++++++++++++++++
web/plugins/views/inventory.py | 9 +++++
4 files changed, 95 insertions(+)
diff --git a/.werks/2979 b/.werks/2979
new file mode 100644
index 0000000..78ced64
--- /dev/null
+++ b/.werks/2979
@@ -0,0 +1,9 @@
+Title: aruba_wlc_aps: new inventory plugin for Aruba Networks WLAN Controller which
displays name, group name, model, serial number and system location of all access points
of this WLC
+Level: 1
+Component: checks
+Compatible: compat
+Version: 1.2.7i4
+Date: 1455118995
+Class: feature
+
+
diff --git a/ChangeLog b/ChangeLog
index 82ca4ab..4f95643 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -114,6 +114,7 @@
* 2989 netapp_api_snapshots: increased performance while querying data. levels
configurable...
* 2977 aruba_wlc_clients: new check which monitors the WLC clients of a Aruba
Networks WLAN Controller
* 3173 datapower_cpu datapower_fan datapower_fs datapower_ldrive datapower_mem
datapower_pdrive datapower_raid_bat datapower_tcp datapower_temp: Detect XI52 Model
+ * 2979 aruba_wlc_aps: new inventory plugin for Aruba Networks WLAN Controller which
displays name, group name, model, serial number and system location of all access points
of this WLC
* 2660 FIX: fixed windows agent using the wrong working directory...
* 2664 FIX: ps: Speedup in situation with many matching processes...
* 2661 FIX: windows agent: fixed incomplete process list...
diff --git a/inventory/aruba_wlc_aps b/inventory/aruba_wlc_aps
new file mode 100644
index 0000000..1cdab56
--- /dev/null
+++ b/inventory/aruba_wlc_aps
@@ -0,0 +1,76 @@
+#!/usr/bin/python
+# -*- encoding: utf-8; py-indent-offset: 4 -*-
+# +------------------------------------------------------------------+
+# | ____ _ _ __ __ _ __ |
+# | / ___| |__ ___ ___| | __ | \/ | |/ / |
+# | | | | '_ \ / _ \/ __| |/ / | |\/| | ' / |
+# | | |___| | | | __/ (__| < | | | | . \ |
+# | \____|_| |_|\___|\___|_|\_\___|_| |_|_|\_\ |
+# | |
+# | Copyright Mathias Kettner 2016 mk(a)mathias-kettner.de |
+# +------------------------------------------------------------------+
+#
+# This file is part of Check_MK.
+# The official homepage is at
http://mathias-kettner.de/check_mk.
+#
+# check_mk is free software; you can redistribute it and/or modify it
+# under the terms of the GNU General Public License as published by
+# the Free Software Foundation in version 2. check_mk is distributed
+# in the hope that it will be useful, but WITHOUT ANY WARRANTY; with-
+# out even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+# PARTICULAR PURPOSE. See the GNU General Public License for more de-
+# tails. You should have received a copy of the GNU General Public
+# License along with GNU Make; see the file COPYING. If not, write
+# to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
+# Boston, MA 02110-1301 USA.
+
+
+# .1.3.6.1.4.1.14823.2.2.1.5.2.1.4.1.3.0.36.108.192.2.186 ALA-AP 2.1.1 -->
WLSX-WLAN-MIB::wlanAPName.'.$l...'
+# .1.3.6.1.4.1.14823.2.2.1.5.2.1.4.1.4.0.36.108.192.2.186 ALA-Office -->
WLSX-WLAN-MIB::wlanAPGroupName.'.$l...'
+# .1.3.6.1.4.1.14823.2.2.1.5.2.1.4.1.5.0.36.108.192.2.186 .1.3.6.1.4.1.14823.1.2.34
--> WLSX-WLAN-MIB::wlanAPModel.'.$l...'
+# .1.3.6.1.4.1.14823.2.2.1.5.2.1.4.1.6.0.36.108.192.2.186 AL0000642 -->
WLSX-WLAN-MIB::wlanAPSerialNumber.'.$l...'
+# .1.3.6.1.4.1.14823.2.2.1.5.2.1.4.1.32.0.36.108.192.2.186 -->
WLSX-WLAN-MIB::wlanAPSysLocation.'.$l...'
+
+
+def inv_aruba_wlc_aps(info):
+ map_ap_products = {
+ "1" : "a50", "2" : "a52", "3"
: "a60", "4" : "a61", "5" : "a70",
+ "6" : "walljackAp61", "7" : "a2E",
"8" : "ap1200", "9" : "ap80s", "10" :
"ap80m",
+ "11" : "wg102", "12" : "ap40",
"13" : "ap41", "14" : "ap65", "15" :
"NesotMW1700",
+ "16" : "ortronics Wi Jack Duo", "17" :
"ortronics Duo", "18" : "ap80MB", "19" :
"ap80SB", "20" : "ap85",
+ "21" : "ap124", "22" : "ap125",
"23" : "ap120", "24" : "ap121", "25" :
"ap1250",
+ "26" : "ap120abg", "27" : "ap121abg",
"28" : "ap124abg", "29" : "ap125abg",
"30" : "rap5wn",
+ "31" : "rap5", "32" : "rap2wg",
"33" : "reserved-4", "34" : "ap105",
"35" : "ap65wb",
+ "36" : "ap651", "37" : "reserved-6",
"38" : "ap60p", "39" : "reserved-7",
"40" : "ap92",
+ "41" : "ap93", "42" : "ap68",
"43" : "ap68p", "44" : "ap175p", "45" :
"ap175ac",
+ "46" : "ap175dc", "47" : "ap134",
"48" : "ap135", "49" : "reserved-8",
"50" : "ap93h",
+ "51" : "rap3wn", "52" : "rap3wnp",
"53" : "ap104", "54" : "rap155", "55" :
"rap155p",
+ "56" : "rap108", "57" : "rap109",
"58" : "ap224", "59" : "ap225", "60" :
"ap114",
+ "61" : "ap115", "62" : "rap109L",
"63" : "ap274", "64" : "ap275", "65" :
"ap214a",
+ "66" : "ap215a", "67" : "ap204",
"68" : "ap205", "69" : "ap103", "70" :
"ap103H",
+ "72" : "ap227", "73" : "ap214",
"74" : "ap215", "75" : "ap228",
+ "76" : "ap205H", "9999" : "undefined",
+ }
+ node = inv_tree("networking.wlan.controller.aps:")
+ for ap_name, ap_gr_name, ap_model, ap_serial_nr, ap_sys_loc in info:
+ node.append({
+ "name" : ap_name,
+ "group" : ap_gr_name,
+ "model" :
map_ap_products.get(ap_model.split(".")[-1], "unknown"),
+ "serial" : ap_serial_nr,
+ "sys_location" : ap_sys_loc,
+ })
+ return node
+
+
+inv_info['aruba_wlc_aps'] = {
+ 'inv_function' : inv_aruba_wlc_aps,
+ "snmp_info" : ( ".1.3.6.1.4.1.14823.2.2.1.5.2.1.4.1",[
+ "3", # wlanAPName
+ "4", # wlanAPGroupName
+ "5", # wlanAPModel
+ "6", # wlanAPSerialNumber
+ "32", # wlanAPSysLocation
+ ]),
+ "snmp_scan_function" : lambda oid:
oid('.1.3.6.1.2.1.1.2.0').startswith(".1.3.6.1.4.1.14823.1.1"),
+}
diff --git a/web/plugins/views/inventory.py b/web/plugins/views/inventory.py
index c4dd663..de41272 100644
--- a/web/plugins/views/inventory.py
+++ b/web/plugins/views/inventory.py
@@ -663,6 +663,15 @@ inventory_displayhints.update({
".networking.interfaces:*.speed" : { "title" :
_("Speed"), "paint" : "nic_speed", },
".networking.interfaces:*.port_type" : { "title" :
_("Type"), "paint" : "if_port_type", "filter" :
visuals.FilterInvtableInterfaceType },
".networking.interfaces:*.last_change" : { "title" :
_("Last Change"), "paint" : "timestamp_as_age_days",
"filter" : visuals.FilterInvtableTimestampAsAge },
+
+ ".networking.wlan" : { "title" :
_("WLAN") },
+ ".networking.wlan.controller" : { "title" :
_("Controller") },
+ ".networking.wlan.controller.accesspoints:" : { "title" :
_("Access Points"), "keyorder" : ["name", "group",
"model", "serial_nr", "sys_location"], "render" :
render_inv_dicttable },
+ ".networking.wlan.controller.accesspoints:*.name" : {
"title" : _("Name") },
+ ".networking.wlan.controller.accesspoints:*.group" : {
"title" : _("Group") },
+ ".networking.wlan.controller.accesspoints:*.model" : {
"title" : _("Model") },
+ ".networking.wlan.controller.accesspoints:*.serial" : {
"title" : _("Serial Number") },
+ ".networking.wlan.controller.accesspoints:*.sys_location" : {
"title" : _("System Location") },
})
# create painters for node with a display hint