mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
Tab => spaces
This commit is contained in:
@@ -3,17 +3,17 @@
|
|||||||
if (!$os) {
|
if (!$os) {
|
||||||
if (preg_match('/ServerIron/', $sysDescr)) {
|
if (preg_match('/ServerIron/', $sysDescr)) {
|
||||||
$os = 'serveriron';
|
$os = 'serveriron';
|
||||||
$serviron_mibs = array (
|
$serviron_mibs = array (
|
||||||
"snL4slbTotalConnections" => "FOUNDRY-SN-SW-L4-SWITCH-GROUP-MIB", // Total connections in this device
|
"snL4slbTotalConnections" => "FOUNDRY-SN-SW-L4-SWITCH-GROUP-MIB", // Total connections in this device
|
||||||
"snL4slbLimitExceeds" => "FOUNDRY-SN-SW-L4-SWITCH-GROUP-MIB", // exceeds snL4TCPSynLimit (numbers of connection per second)
|
"snL4slbLimitExceeds" => "FOUNDRY-SN-SW-L4-SWITCH-GROUP-MIB", // exceeds snL4TCPSynLimit (numbers of connection per second)
|
||||||
"snL4slbForwardTraffic" => "FOUNDRY-SN-SW-L4-SWITCH-GROUP-MIB", // Client->Server
|
"snL4slbForwardTraffic" => "FOUNDRY-SN-SW-L4-SWITCH-GROUP-MIB", // Client->Server
|
||||||
"snL4slbReverseTraffic" => "FOUNDRY-SN-SW-L4-SWITCH-GROUP-MIB", // Server->Client
|
"snL4slbReverseTraffic" => "FOUNDRY-SN-SW-L4-SWITCH-GROUP-MIB", // Server->Client
|
||||||
"snL4slbFinished" => "FOUNDRY-SN-SW-L4-SWITCH-GROUP-MIB", // FIN_or_RST
|
"snL4slbFinished" => "FOUNDRY-SN-SW-L4-SWITCH-GROUP-MIB", // FIN_or_RST
|
||||||
"snL4FreeSessionCount" => "FOUNDRY-SN-SW-L4-SWITCH-GROUP-MIB", // Maximum sessions - used sessions
|
"snL4FreeSessionCount" => "FOUNDRY-SN-SW-L4-SWITCH-GROUP-MIB", // Maximum sessions - used sessions
|
||||||
"snL4unsuccessfulConn" => "FOUNDRY-SN-SW-L4-SWITCH-GROUP-MIB", // Unsuccessfull connection
|
"snL4unsuccessfulConn" => "FOUNDRY-SN-SW-L4-SWITCH-GROUP-MIB", // Unsuccessfull connection
|
||||||
);
|
);
|
||||||
|
|
||||||
register_mibs($device, $serviron_mibs, "includes/discovery/os/serveriron.inc.php");
|
register_mibs($device, $serviron_mibs, "includes/discovery/os/serveriron.inc.php");
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -4,8 +4,8 @@ if ($device['os'] == 'serveriron') {
|
|||||||
echo(" FOUNDRY-SN-AGENT-MIB");
|
echo(" FOUNDRY-SN-AGENT-MIB");
|
||||||
|
|
||||||
// Chassis temperature (default)
|
// Chassis temperature (default)
|
||||||
$high_limit = 110;
|
$high_limit = 110;
|
||||||
$high_warn_limit = 95;
|
$high_warn_limit = 95;
|
||||||
|
|
||||||
$descr = "Chassis Temperature";
|
$descr = "Chassis Temperature";
|
||||||
$oid = "1.3.6.1.4.1.1991.1.1.1.1.18.0"; // snChasActualTemperature
|
$oid = "1.3.6.1.4.1.1991.1.1.1.1.18.0"; // snChasActualTemperature
|
||||||
@@ -16,16 +16,16 @@ if ($device['os'] == 'serveriron') {
|
|||||||
|
|
||||||
$value_warn = snmp_get($device, $warn_oid, '-Oqv');
|
$value_warn = snmp_get($device, $warn_oid, '-Oqv');
|
||||||
if (is_numeric($value_warn)) {
|
if (is_numeric($value_warn)) {
|
||||||
$high_warn_limit = ($value_warn / 2);
|
$high_warn_limit = ($value_warn / 2);
|
||||||
}
|
}
|
||||||
|
|
||||||
$value_high = snmp_get($device, $high_oid, '-Oqv');
|
$value_high = snmp_get($device, $high_oid, '-Oqv');
|
||||||
if (is_numeric($value_high)) {
|
if (is_numeric($value_high)) {
|
||||||
$high_limit = ($value_high / 2);
|
$high_limit = ($value_high / 2);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (is_numeric($value)) {
|
if (is_numeric($value)) {
|
||||||
$current = ($value / 2);
|
$current = ($value / 2);
|
||||||
discover_sensor($valid['sensor'], 'temperature', $device, $oid, 1, 'serveriron-temp', $descr, '2', '1', null, null, $high_warn_limit, $high_limit, $current);
|
discover_sensor($valid['sensor'], 'temperature', $device, $oid, 1, 'serveriron-temp', $descr, '2', '1', null, null, $high_warn_limit, $high_limit, $current);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user