mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
apc and arista fixes from fenestro
git-svn-id: http://www.observium.org/svn/observer/trunk@1862 61d68cd4-352d-0410-923a-c4978735b2b8
This commit is contained in:
@ -17,6 +17,27 @@ if ($device['os'] == "apc")
|
||||
|
||||
discover_sensor($valid_sensor, 'temperature', $device, $oid, $index, 'apc', $descr, '1', '1', NULL, NULL, NULL, NULL, $current);
|
||||
}
|
||||
# InRow Chiller.
|
||||
# A silly check to find out if it's the right hardware.
|
||||
$oids = snmp_get($device, "airIRRCGroupSetpointsCoolMetric.0", "-OsqnU", "PowerNet-MIB");
|
||||
if ($oids)
|
||||
{
|
||||
echo("APC InRow Chiller ");
|
||||
$temps = array();
|
||||
$temps['airIRRCUnitStatusRackInletTempMetric'] = "Rack Inlet";
|
||||
$temps['airIRRCUnitStatusSupplyAirTempMetric'] = "Supply Air";
|
||||
$temps['airIRRCUnitStatusReturnAirTempMetric'] = "Return Air";
|
||||
$temps['airIRRCUnitStatusEnteringFluidTemperatureMetric'] = "Entering Fluid";
|
||||
$temps['airIRRCUnitStatusLeavingFluidTemperatureMetric'] = "Leaving Fluid";
|
||||
foreach($temps as $obj => $descr)
|
||||
{
|
||||
$oids = snmp_get($device, $obj . ".0", "-OsqnU", "PowerNet-MIB");
|
||||
list($oid,$current) = explode(' ',$oids);
|
||||
$divisor = 10;
|
||||
$sensorType = substr($descr, 0, 2);
|
||||
echo(discover_sensor($valid_sensor, 'temperature', $device, $oid, '0', $sensorType, $descr, $divisor, '1', NULL, NULL, NULL, NULL, $current));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
?>
|
||||
?>
|
||||
|
@ -1,6 +1,6 @@
|
||||
<?php
|
||||
|
||||
$version = preg_replace("/.+ version (.+) running on .+ (\S+)$/", "\||\\2", $sysDescr );
|
||||
$version = preg_replace("/.+ version (.+) running on .+ (\S+)$/", "\\1||\\2", $sysDescr );
|
||||
list($version,$hardware) = explode("||", $version);
|
||||
|
||||
?>
|
Reference in New Issue
Block a user