mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
Removed double Stack Temperature Discovery and Fixed typos in dbm discovery for Dell Switches (#10630)
* Fixed typos in dbm discovery for Dell Switches Fixed typos in dbm discovery for Dell Switches * Skip value 0 in temperature sensors * Update dnos.yaml * Remove temp M-serie from php, already in yaml * Create dnos_s4048.snmpsim * Rename dnos_s4048.snmpsim to dnos_s4048.snmprec * Create dnos_s4048.json * Create dell-net.inc.php Added mempool for Dell Net switches * Update dnos.yaml Removed whitespaces in dnos.yaml * Update dnos_s4048.json * Delete dnos.json * Create dnos.json
This commit is contained in:
committed by
Tony Murray
co-authored by
Tony Murray
parent
cbc307c1c7
commit
610fde83ec
@@ -98,7 +98,7 @@ modules:
|
||||
value: dellNetIfTransReceivePowerLane2
|
||||
num_oid: '.1.3.6.1.4.1.6027.3.11.1.3.1.1.13.{{ $index }}'
|
||||
descr: 'Rx {{ $dellNetIfTransPort }} {{ $dellNetIfTransOpticsType }}'
|
||||
index: 'dellNetIfTransReceivePowerLane1.{{ $index }}'
|
||||
index: 'dellNetIfTransReceivePowerLane2.{{ $index }}'
|
||||
group: Lane 2
|
||||
-
|
||||
snmp_flags: ['-ObsQ']
|
||||
@@ -111,7 +111,7 @@ modules:
|
||||
-
|
||||
snmp_flags: ['-ObsQ']
|
||||
oid: dellNetIfTransceiverDataTable
|
||||
value: dellNetIfTransReceivePowerLane1
|
||||
value: dellNetIfTransReceivePowerLane3
|
||||
num_oid: '.1.3.6.1.4.1.6027.3.11.1.3.1.1.14.{{ $index }}'
|
||||
descr: 'Rx {{ $dellNetIfTransPort }} {{ $dellNetIfTransOpticsType }}'
|
||||
index: 'dellNetIfTransReceivePowerLane3.{{ $index }}'
|
||||
@@ -133,6 +133,8 @@ modules:
|
||||
index: 'dellNetIfTransReceivePowerLane4.{{ $index }}'
|
||||
group: Lane 4
|
||||
temperature:
|
||||
options:
|
||||
skip_values: 0
|
||||
data:
|
||||
-
|
||||
oid: dellNetStackUnitTable
|
||||
|
||||
@@ -33,19 +33,3 @@ if (is_array($oids)) {
|
||||
discover_sensor($valid['sensor'], 'temperature', $device, $oid, $index, 'ftos-sseries', $descr, '1', '1', null, null, null, null, $current);
|
||||
}
|
||||
}
|
||||
|
||||
// Force10 M-Series
|
||||
// DELL-NETWORKING-CHASSIS-MIB::dellNetStackUnitTemp.1 = Gauge32: 67
|
||||
// DELL-NETWORKING-CHASSIS-MIB::dellNetStackUnitModelId.1 = INTEGER: m-MXL(25)
|
||||
echo 'FTOS M-Series ';
|
||||
|
||||
$oids = snmpwalk_cache_oid($device, 'dellNetStackUnitTemp', [], 'DELL-NETWORKING-CHASSIS-MIB', 'dnos');
|
||||
|
||||
if (is_array($oids)) {
|
||||
foreach ($oids as $index => $entry) {
|
||||
$descr = 'Unit '.$index;
|
||||
$oid = '.1.3.6.1.4.1.6027.3.26.1.3.4.1.13.'.$index;
|
||||
$current = $entry['dellNetStackUnitTemp'];
|
||||
discover_sensor($valid['sensor'], 'temperature', $device, $oid, $index, 'dnos', $descr, '1', '1', null, null, null, null, $current);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,21 @@
|
||||
<?php
|
||||
/*
|
||||
* * LibreNMS DELL net memory information module
|
||||
* *
|
||||
* * Copyright (c) 2019 Erik van Helden
|
||||
* * 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.
|
||||
* */
|
||||
|
||||
$total = snmp_get($device, '.1.3.6.1.4.1.6027.3.26.1.4.3.1.6.2.1.1', '-OvQ');
|
||||
$usage = snmp_get($device, '.1.3.6.1.4.1.6027.3.26.1.4.4.1.6.2.1.1', '-OvQ');
|
||||
$usage_perc = $usage / 100;
|
||||
$used = $total * $usage_perc;
|
||||
$free = $total - $used;
|
||||
|
||||
$mempool['total'] = $total * 1024 * 1024;
|
||||
$mempool['free'] = $free * 1024 * 1024;
|
||||
$mempool['used'] = $used * 1024 * 1024;
|
||||
+20
-73
@@ -27033,78 +27033,6 @@
|
||||
"sensor_prev": null,
|
||||
"user_func": null,
|
||||
"state_name": null
|
||||
},
|
||||
{
|
||||
"sensor_deleted": 0,
|
||||
"sensor_class": "temperature",
|
||||
"poller_type": "snmp",
|
||||
"sensor_oid": ".1.3.6.1.4.1.6027.3.11.1.3.1.1.16.2103301",
|
||||
"sensor_index": "2103301",
|
||||
"sensor_type": "dnos",
|
||||
"sensor_descr": "Fo 1/49 40GBASE-CR4-7M",
|
||||
"group": "Transceivers",
|
||||
"sensor_divisor": 1,
|
||||
"sensor_multiplier": 1,
|
||||
"sensor_current": 0,
|
||||
"sensor_limit": 20,
|
||||
"sensor_limit_warn": null,
|
||||
"sensor_limit_low": -10,
|
||||
"sensor_limit_low_warn": null,
|
||||
"sensor_alert": 1,
|
||||
"sensor_custom": "No",
|
||||
"entPhysicalIndex": null,
|
||||
"entPhysicalIndex_measured": null,
|
||||
"sensor_prev": null,
|
||||
"user_func": null,
|
||||
"state_name": null
|
||||
},
|
||||
{
|
||||
"sensor_deleted": 0,
|
||||
"sensor_class": "temperature",
|
||||
"poller_type": "snmp",
|
||||
"sensor_oid": ".1.3.6.1.4.1.6027.3.11.1.3.1.1.16.2105349",
|
||||
"sensor_index": "2105349",
|
||||
"sensor_type": "dnos",
|
||||
"sensor_descr": "Fo 1/53 40GBASE-CR4-0.5M",
|
||||
"group": "Transceivers",
|
||||
"sensor_divisor": 1,
|
||||
"sensor_multiplier": 1,
|
||||
"sensor_current": 0,
|
||||
"sensor_limit": 20,
|
||||
"sensor_limit_warn": null,
|
||||
"sensor_limit_low": -10,
|
||||
"sensor_limit_low_warn": null,
|
||||
"sensor_alert": 1,
|
||||
"sensor_custom": "No",
|
||||
"entPhysicalIndex": null,
|
||||
"entPhysicalIndex_measured": null,
|
||||
"sensor_prev": null,
|
||||
"user_func": null,
|
||||
"state_name": null
|
||||
},
|
||||
{
|
||||
"sensor_deleted": 0,
|
||||
"sensor_class": "temperature",
|
||||
"poller_type": "snmp",
|
||||
"sensor_oid": ".1.3.6.1.4.1.6027.3.11.1.3.1.1.16.2105861",
|
||||
"sensor_index": "2105861",
|
||||
"sensor_type": "dnos",
|
||||
"sensor_descr": "Fo 1/54 40GBASE-CR4-0.5M",
|
||||
"group": "Transceivers",
|
||||
"sensor_divisor": 1,
|
||||
"sensor_multiplier": 1,
|
||||
"sensor_current": 0,
|
||||
"sensor_limit": 20,
|
||||
"sensor_limit_warn": null,
|
||||
"sensor_limit_low": -10,
|
||||
"sensor_limit_low_warn": null,
|
||||
"sensor_alert": 1,
|
||||
"sensor_custom": "No",
|
||||
"entPhysicalIndex": null,
|
||||
"entPhysicalIndex_measured": null,
|
||||
"sensor_prev": null,
|
||||
"user_func": null,
|
||||
"state_name": null
|
||||
}
|
||||
],
|
||||
"state_indexes": [
|
||||
@@ -27175,6 +27103,25 @@
|
||||
}
|
||||
]
|
||||
},
|
||||
"poller": "matches discovery"
|
||||
"poller": {
|
||||
"mempools": [
|
||||
{
|
||||
"mempool_index": "stack.1.1",
|
||||
"entPhysicalIndex": null,
|
||||
"hrDeviceIndex": null,
|
||||
"mempool_type": "dell-net",
|
||||
"mempool_precision": 0,
|
||||
"mempool_descr": "Memory Usage",
|
||||
"mempool_perc": 30,
|
||||
"mempool_used": 644245094,
|
||||
"mempool_free": 1503238554,
|
||||
"mempool_total": 2147483648,
|
||||
"mempool_largestfree": null,
|
||||
"mempool_lowestfree": null,
|
||||
"mempool_deleted": 0,
|
||||
"mempool_perc_warn": 90
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user