mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
more adama general failures fixup
git-svn-id: http://www.observium.org/svn/observer/trunk@858 61d68cd4-352d-0410-923a-c4978735b2b8
This commit is contained in:
@@ -64,7 +64,7 @@ if ($device['os'] == "linux")
|
||||
$monitor = snmp_get($device, $monitor_oid, "-Oqv", "SUPERMICRO-HEALTH-MIB");
|
||||
if ($monitor == 'true')
|
||||
{
|
||||
echo discover_fan($device, $fan_oid, $index, $type, $descr, $precision, NULL, $limit, $current);
|
||||
echo discover_fan($device, $fan_oid, $index, $type, $descr, $precision, $limit, NULL, $current);
|
||||
$fan_exists[$type][$index] = 1;
|
||||
}
|
||||
}
|
||||
|
@@ -16,7 +16,7 @@ function discover_fan($device, $oid, $index, $type, $descr, $precision = 1, $low
|
||||
if($oid == $fan_entry['fan_oid'] && $descr == $fan_entry['fan_descr'] && $precision == $fan_entry['fan_precision']) {
|
||||
echo(".");
|
||||
} else {
|
||||
mysql_query("UPDATE fanspeed SET `fan_descr` = '$descr', `fan_oid` = '$oid', `fan_precision` = '$precision' WHERE `device_id` = '$id' AND fan_type = '$type' AND `fan_index` = '$fan_index' ");
|
||||
mysql_query("UPDATE fanspeed SET `fan_descr` = '$descr', `fan_oid` = '$oid', `fan_precision` = '$precision' WHERE `device_id` = '".$device['device_id']."' AND fan_type = '$type' AND `fan_index` = '$fan_index' ");
|
||||
echo("U");
|
||||
}
|
||||
}
|
||||
|
@@ -51,8 +51,9 @@ if ($device['os'] == "junos")
|
||||
$peer_cmd .= " jnxBgpM2PeerFsmEstablishedTime.0.ipv6." . $junos_v6[$peer_ip];
|
||||
$peer_cmd .= " jnxBgpM2PeerInUpdatesElapsedTime.0.ipv6." . $junos_v6[$peer_ip];
|
||||
$peer_cmd .= " jnxBgpM2PeerLocalAddr.0.ipv6." . $junos_v6[$peer_ip];
|
||||
$peer_data = trim(`$peer_cmd . '|grep -v "No Such Instance"'`);
|
||||
$peer_cmd .= ' -M"+' . $config['install_dir'] . '/mibs/junos"|grep -v "No Such Instance"';
|
||||
if ($debug) echo "\n$peer_cmd\n";
|
||||
$peer_data = trim(`$peer_cmd`);
|
||||
list($bgpPeerState, $bgpPeerAdminStatus, $bgpPeerInUpdates, $bgpPeerOutUpdates, $bgpPeerInTotalMessages, $bgpPeerOutTotalMessages, $bgpPeerFsmEstablishedTime, $bgpPeerInUpdateElapsedTime, $bgpLocalAddr) = explode("\n", $peer_data);
|
||||
|
||||
if ($debug) { echo "State = $bgpPeerState - AdminStatus: $bgpPeerAdminStatus\n"; }
|
||||
|
Reference in New Issue
Block a user