mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
device_processor_stacked type for unix devices (where all CPUs share the same domain, not useful on network hardware where different CPUs do different jobs) Also we need inherit properties to $config['os'] from $config['os_group'], where they are not already set in $config['os']. Also updog.
git-svn-id: http://www.observium.org/svn/observer/trunk@2138 61d68cd4-352d-0410-923a-c4978735b2b8
This commit is contained in:
38
html/includes/graphs/device/processor_stack.inc.php
Normal file
38
html/includes/graphs/device/processor_stack.inc.php
Normal file
@@ -0,0 +1,38 @@
|
||||
<?php
|
||||
|
||||
#$device = device_by_id_cache($id);
|
||||
#$query = mysql_query("SELECT * FROM `processors` where `device_id` = '".$id."'");
|
||||
|
||||
$i = 0;
|
||||
|
||||
while ($proc = mysql_fetch_assoc($query))
|
||||
{
|
||||
$rrd_filename = $config['rrd_dir'] . "/".$device['hostname']."/" . safename("processor-" . $proc['processor_type'] . "-" . $proc['processor_index'] . ".rrd");
|
||||
|
||||
if (is_file($rrd_filename))
|
||||
{
|
||||
$descr = short_hrDeviceDescr($proc['processor_descr']);
|
||||
|
||||
$rrd_list[$i]['filename'] = $rrd_filename;
|
||||
$rrd_list[$i]['descr'] = $descr;
|
||||
$rrd_list[$i]['rra'] = "usage";
|
||||
$i++;
|
||||
}
|
||||
}
|
||||
|
||||
$unit_text = "Load %";
|
||||
|
||||
$units = '%';
|
||||
$total_units = '%';
|
||||
$colours ='oranges';
|
||||
|
||||
$scale_min = "0";
|
||||
$scale_max = "100";
|
||||
|
||||
$divider = $i;
|
||||
$text_orig = 1;
|
||||
$nototal = 1;
|
||||
|
||||
include("includes/graphs/generic_multi_simplex_seperated.inc.php");
|
||||
|
||||
?>
|
Reference in New Issue
Block a user