Files
Andrew Holmes 0ba372221f fix: Cambium ePMP CPU reporting fix (#7182)
* Commit merge to branch for Cambium CPU fix (#1)

* Remove division by 10

Removes unnecessary division by 10 from poller file; this is handled by processor_precision in the main include.

* Correct processor_precision

Adjusted processor precision divider from 100 to 10 (as sysCPUUsage.0 reports from 0-1000 as 0-100.0%)

* Delete cambium-cpu.inc.php

With the change to the discovery file (processor_precision set to the correct value of 10) this file is not required.
2017-08-21 08:02:51 +01:00

31 lines
861 B
PHP

<?php
/*
*
* This program 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, either version 3 of the License, or (at your
* option) any later version. Please see LICENSE.txt at the top level of
* the source code distribution for details.
*/
if ($device['os'] == 'cambium') {
echo 'Cambium : ';
$descr = 'Processor';
$usage = str_replace('"', "", snmp_get($device, 'CAMBIUM-PMP80211-MIB::sysCPUUsage.0', '-OvQ'));
if (is_numeric($usage)) {
discover_processor(
$valid['processor'],
$device,
'CAMBIUM-PMP80211-MIB::sysCPUUsage.0',
'0',
'cambium-cpu',
$descr,
'10',
$usage,
null,
null
);
}
}