Basic support for Xirrus Wireless Access Points. #3543

Merged
merged 10 commits into from May 30, 2016

Projects

None yet

6 participants

@Tatermen
Contributor

Add basic support for Xirrus Wireless Access Points.

This may need further work - the wifi polling code only appears to support graphing the station count for two radios - Xirrus APs can have upto 16, but I only have access to a two radio model at present.

Tatermen added some commits May 23, 2016
@Tatermen Tatermen Basic support for Xirrus Wireless Access Points.
I agree to the conditions of the Contributor Agreement contained in doc/General/Contributing.md.
bbc8a09
@Tatermen Tatermen Removed debugging line.
97750c0
@murrant murrant and 1 other commented on an outdated diff May 24, 2016
includes/discovery/os/xirrus.inc.php
@@ -0,0 +1,9 @@
+<?php
+
+if(!$os) {
+ if (strstr($sysDescr, 'Xirrus')) {
+ $os = 'xirrus';
+ }
+}
+
+?>
@murrant
murrant May 24, 2016 Contributor

Please remove the ?>

@Tatermen
Tatermen May 24, 2016 Contributor

Took me two attempts, but it's gone :)

Tatermen added some commits May 24, 2016
@Tatermen Tatermen Removed ?> from OS discovery as requested. Added Xirrus specific RSSI…
… graph.
191fe25
@Tatermen Tatermen Removed ?>
39f8371
@f0o f0o commented on an outdated diff May 25, 2016
includes/polling/wireless/xirrus.inc.php
+$radios = snmpwalk_cache_oid($device, 'XIRRUS-MIB::realtimeMonitorIfaceName', array(), 'XIRRUS-MIB');
+$rssi = snmpwalk_cache_oid($device, 'XIRRUS-MIB::realtimeMonitorAverageRSSI', array(), 'XIRRUS-MIB');
+foreach($radios as $idx => $radio) {
+
+ $radioName = $radio['realtimeMonitorIfaceName'];
+ $rrd_filename = $config['rrd_dir'] . "/" . $device['hostname'] . "/xirrus_rssi-$idx.rrd";
+ if (!is_file($rrd_filename)) {
+ rrdtool_create($rrd_filename, " --step 300 DS:rssi:GAUGE:600:-150:0".$config['rrd_rra']);
+ }
+ rrdtool_update($rrd_filename, array('rssi'=>$rssi[$idx]['realtimeMonitorAverageRSSI']));
+
+}
+// cleanup
+unset($rrd_filename); unset($radios); unset($rssi); unset($radioName);
+$graphs['xirrus_rssi'] = TRUE;
+?>
@f0o
f0o May 25, 2016 Member

Please remove this line

@Tatermen Tatermen Removed ?> from includes/polling/wireless/xirrus.inc.php. Also added …
…graphs for average data rates and noise floor and a custom graph for clients connected per radio that should work on larger models.
ae23432
@geordish
Contributor

I think this needs to be ArrayOS as the OS

@stevewalsh

I have snmp read access to a bunch of Xirrus arrays for a conference until 2 June. Please let me know what sort of information you need, and I'll run snmpwalks against the devices I have access to.

@Tatermen Tatermen Changed OS name to "Xirrus ArrayOS" and internal OS name to 'xirrus_os'.
31d4a29
@Tatermen
Contributor
Tatermen commented May 26, 2016 edited

You're right - I've changed the OS name to "Xirrus ArrayOS" (internally xirrus_aos) which should prevent any conflicts.

I've written it to walk the following OIDs, to get the majority of the stats:

XIRRUS-MIB::realtimeMonitorIfaceName
XIRRUS-MIB::realtimeMonitorAverageRSSI
XIRRUS-MIB::realtimeMonitorAverageDataRate
XIRRUS-MIB::realtimeMonitorNoiseFloor

On my Xirrus XR620 which only has two radios, these return tables with an OID for each radio:

XIRRUS-MIB::realtimeMonitorIfaceName.1 = STRING: iap1
XIRRUS-MIB::realtimeMonitorIfaceName.2 = STRING: iap2
XIRRUS-MIB::realtimeMonitorAverageRSSI.1 = INTEGER: -93
XIRRUS-MIB::realtimeMonitorAverageRSSI.2 = INTEGER: 0
XIRRUS-MIB::realtimeMonitorAverageDataRate.1 = INTEGER: 59
XIRRUS-MIB::realtimeMonitorAverageDataRate.2 = INTEGER: 0
XIRRUS-MIB::realtimeMonitorNoiseFloor.1 = INTEGER: -102
XIRRUS-MIB::realtimeMonitorNoiseFloor.2 = INTEGER: 0

So I've written the code on the assumption that further radios will show up as additional OIDs, eg:

XIRRUS-MIB::realtimeMonitorIfaceName.3 = STRING: iap3
XIRRUS-MIB::realtimeMonitorIfaceName.4 = STRING: iap4

if this is correct, then I'm confident the code I've written should correctly poll the additional radios. Station associations work in a similar manner, where there is a table of OIDs of associations' MAC addresses, IPs, device names etc, as well as what radio they are connected to:

XIRRUS-MIB::stationAssociationIAP.1 = STRING: iap1
XIRRUS-MIB::stationAssociationIAP.2 = STRING: iap2
XIRRUS-MIB::stationAssociationIAP.3 = STRING: iap1
XIRRUS-MIB::stationAssociationIAP.4 = STRING: iap1

So again I'm assuming that additional radios will be called iap3, iap4, iap5 and so on. An issue with doing this may be that it may take a long time to poll an AP that has hundreds or thousands of users on it, but there does not appear to be any OIDs that just list a count of stations per radio.

@Tatermen Tatermen Fixed formatting.
e5a21b0
@laf
Member
laf commented May 26, 2016

How likely is it to have 100's / 1000's of users on each AP? We wouldn't want to slow polling down for people who heavily use these.

@Tatermen
Contributor

Not too likely I would think. To the best of my knowledge the ones that support thousands of users costs $40-50,000.

I could add a configuration flag to disable the station/user polling if you think it could be of concern, something like $config['xirrus_disable_stations'] ?

@laf
Member
laf commented May 26, 2016

I'd say that would be best - just in case.

Tatermen added some commits May 26, 2016
@Tatermen Tatermen Renamed includes/polling/os/xirrus.inc.php per change in OS name. Derp.
bd842f6
@Tatermen Tatermen Added config flag ($config['xirrus_disable_stations']) to disable sta…
…tion polling.
524bf05
@geordish
Contributor

You should probably set a default value for $config['xirrus_disable_stations'] in includes/defaults.inc.php

@Tatermen Tatermen Added config option to includes/defaults.inc.php
ddb04ad
@Tatermen
Contributor

Done. I didn't realize that existed,

@laf laf merged commit 5d49f72 into librenms:master May 30, 2016

1 of 2 checks passed

Auto-Deploy Triggered
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment