mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
only repoll capacity when oid is in database
git-svn-id: http://www.observium.org/svn/observer/trunk@3139 61d68cd4-352d-0410-923a-c4978735b2b8
This commit is contained in:
@ -8,7 +8,10 @@ if ($config['enable_printers'])
|
||||
{
|
||||
echo("Checking toner " . $toner['toner_descr'] . "... ");
|
||||
|
||||
$toner['toner_capacity'] = snmp_get($device, $toner['toner_capacity_oid'], "-OUqnv");
|
||||
if ($toner['toner_capacity_oid']) # FIXME this if can go on 1-Sep-2012
|
||||
{
|
||||
$toner['toner_capacity'] = snmp_get($device, $toner['toner_capacity_oid'], "-OUqnv");
|
||||
}
|
||||
$tonerperc = round(snmp_get($device, $toner['toner_oid'], "-OUqnv") / $toner['toner_capacity'] * 100);
|
||||
|
||||
$old_tonerrrd = $config['rrd_dir'] . "/" . $device['hostname'] . "/" . safename("toner-" . $toner['toner_descr'] . ".rrd");
|
||||
|
Reference in New Issue
Block a user