small fixes

git-svn-id: http://www.observium.org/svn/observer/trunk@1755 61d68cd4-352d-0410-923a-c4978735b2b8
This commit is contained in:
Tom Laermans
2010-12-03 15:56:57 +00:00
parent 3133a5b2fd
commit 73135beb95
3 changed files with 95 additions and 84 deletions
+3 -3
View File
@@ -4,7 +4,7 @@ global $valid_sensor;
if (strstr($device['hardware'], "dell"))
{
$oids = snmp_walk($device, ".1.3.6.1.4.1.674.10892.1.700.20.1.8", "-Osqn", "MIB-Dell-10892");
$oids = snmp_walk($device, "coolingDeviceDiscreteReading", "-Osqn", "MIB-Dell-10892");
$oids = trim($oids);
if ($oids) echo("Dell OMSA ");
foreach(explode("\n",$oids) as $oid)
@@ -16,8 +16,8 @@ if (strstr($device['hardware'], "dell"))
$descr_query = snmp_get($device, ".1.3.6.1.4.1.674.10892.1.700.20.1.8.$oid", "-Onvq", "MIB-Dell-10892");
$descr = trim(str_replace("\"", "", shell_exec($descr_query)));
$fulloid = ".1.3.6.1.4.1.674.10892.1.700.20.1.6.$oid";
### FIXME CURRENT
discover_sensor($valid_sensor, 'temperature', $device, $fulloid, $oid, 'dell', $descr, '10', '1', NULL, NULL, NULL, NULL, NULL);
$temp = snmp_get($device, $fulloid, "-Oqv");
discover_sensor($valid_sensor, 'temperature', $device, $fulloid, $oid, 'dell', $descr, '10', '1', NULL, NULL, NULL, NULL, $temp);
}
}
}