Files
librenms-librenms/includes/polling/os/arbos.inc.php
Tony Murray 020c5fd7e1 Remove legacy code and fix missing device graphs (#11950)
* removing $graphs global

* remove unused things

* fix some additional graphs

* Fix graphs persisting too soon

* correct name for poller module performance graph

* only one type of graph is used here
2020-07-23 09:57:22 -05:00

21 lines
456 B
PHP

<?php
use LibreNMS\RRD\RrdDefinition;
$oids = snmp_get_multi($device, 'deviceTotalFlows.0', '-OQUs', 'PEAKFLOW-SP-MIB');
$flows = $oids[0]['deviceTotalFlows'];
if (is_numeric($flows)) {
$rrd_def = RrdDefinition::make()->addDataset('flows', 'GAUGE', 0, 3000000);
$fields = array(
'flows' => $flows,
);
$tags = compact('rrd_def');
data_update($device, 'arbos_flows', $tags, $fields);
$os->enableGraph('arbos_flows');
}