mirror of
https://github.com/stylersnico/librenms.git
synced 2026-07-28 00:24:21 +02:00
Finished dell rac support and updated mib
This commit is contained in:
@@ -0,0 +1,9 @@
|
||||
<?php
|
||||
|
||||
$class = "state";
|
||||
$unit = "";
|
||||
$unit_long = "State";
|
||||
|
||||
include("includes/graphs/device/sensor.inc.php");
|
||||
|
||||
?>
|
||||
@@ -0,0 +1,17 @@
|
||||
<?php
|
||||
|
||||
$scale_min = "0";
|
||||
$scale_max = "10";
|
||||
|
||||
include("includes/graphs/common.inc.php");
|
||||
|
||||
$rrd_options .= " COMMENT:' Min Max Last\\n'";
|
||||
$rrd_options .= " DEF:sensor=$rrd_filename:sensor:AVERAGE";
|
||||
$rrd_options .= " LINE1.5:sensor#cc0000:'" . rrdtool_escape($sensor['sensor_descr'],21)."'";
|
||||
$rrd_options .= " GPRINT:sensor:MIN:%4.1lf";
|
||||
$rrd_options .= " GPRINT:sensor:MAX:%4.1lf";
|
||||
$rrd_options .= " GPRINT:sensor:LAST:%4.1lf\\\\l";
|
||||
|
||||
if (is_numeric($sensor['sensor_limit'])) $rrd_options .= " HRULE:".$sensor['sensor_limit']."#999999::dashes";
|
||||
if (is_numeric($sensor['sensor_limit_low'])) $rrd_options .= " HRULE:".$sensor['sensor_limit_low']."#999999::dashes";
|
||||
|
||||
@@ -14,6 +14,7 @@ $current = dbFetchCell("select count(*) from sensors WHERE sensor_class='cu
|
||||
$freqs = dbFetchCell("select count(*) from sensors WHERE sensor_class='frequency' AND device_id = ?", array($device['device_id']));
|
||||
$power = dbFetchCell("select count(*) from sensors WHERE sensor_class='power' AND device_id = ?", array($device['device_id']));
|
||||
$dBm = dbFetchCell("select count(*) from sensors WHERE sensor_class='dBm' AND device_id = ?", array($device['device_id']));
|
||||
$states = dbFetchCell("select count(*) from sensors WHERE sensor_class='state' AND device_id = ?", array($device['device_id']));
|
||||
|
||||
unset($datas);
|
||||
$datas[] = 'overview';
|
||||
@@ -30,6 +31,7 @@ if ($freqs) { $datas[] = 'frequency'; }
|
||||
if ($current) { $datas[] = 'current'; }
|
||||
if ($power) { $datas[] = 'power'; }
|
||||
if ($dBm) { $datas[] = 'dbm'; }
|
||||
if ($states) { $datas[] = 'state'; }
|
||||
|
||||
$type_text['overview'] = "Overview";
|
||||
$type_text['charge'] = "Battery Charge";
|
||||
@@ -45,6 +47,7 @@ $type_text['frequency'] = "Frequency";
|
||||
$type_text['current'] = "Current";
|
||||
$type_text['power'] = "Power";
|
||||
$type_text['dbm'] = "dBm";
|
||||
$type_text['state'] = "State";
|
||||
|
||||
$link_array = array('page' => 'device',
|
||||
'device' => $device['device_id'],
|
||||
|
||||
@@ -0,0 +1,7 @@
|
||||
<?php
|
||||
|
||||
$class = "state";
|
||||
$unit = "";
|
||||
$graph_type = "sensor_state";
|
||||
|
||||
include("sensors.inc.php");
|
||||
Reference in New Issue
Block a user