Commit version 24.12.13800
This commit is contained in:
@ -1,5 +1,4 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Observium
|
||||
*
|
||||
@ -7,24 +6,25 @@
|
||||
*
|
||||
* @package observium
|
||||
* @subpackage graphs
|
||||
* @copyright (C) 2006-2013 Adam Armstrong, (C) 2013-2019 Observium Limited
|
||||
* @copyright (C) Adam Armstrong
|
||||
*
|
||||
*/
|
||||
|
||||
if (is_numeric($vars['id']))
|
||||
{
|
||||
$disk = dbFetchRow("SELECT * FROM `ucd_diskio` AS U, `devices` AS D WHERE U.diskio_id = ? AND U.device_id = D.device_id", array($vars['id']));
|
||||
if (!is_intnum($vars['id'])) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (is_numeric($disk['device_id']) && ($auth || device_permitted($disk['device_id'])))
|
||||
{
|
||||
$disk = dbFetchRow("SELECT * FROM `ucd_diskio` WHERE `diskio_id` = ?", [$vars['id']]);
|
||||
|
||||
if (is_numeric($disk['device_id']) && ($auth || device_permitted($disk['device_id']))) {
|
||||
$device = device_by_id_cache($disk['device_id']);
|
||||
|
||||
$rrd_filename = get_rrd_path($device, "ucd_diskio-" . $disk['diskio_descr'] . ".rrd");
|
||||
|
||||
$title = generate_device_link($device);
|
||||
$title .= " :: Disk :: " . escape_html($disk['diskio_descr']);
|
||||
$auth = TRUE;
|
||||
}
|
||||
$auth = TRUE;
|
||||
|
||||
$graph_title = device_name($device, TRUE);
|
||||
$graph_title .= " :: Disk :: " . $disk['diskio_descr'];
|
||||
}
|
||||
|
||||
// EOF
|
||||
|
@ -5,17 +5,17 @@
|
||||
*
|
||||
* This file is part of Observium.
|
||||
*
|
||||
* @package observium
|
||||
* @subpackage graphs
|
||||
* @copyright (C) 2006-2013 Adam Armstrong, (C) 2013-2019 Observium Limited
|
||||
* @package observium
|
||||
* @subpackage graphs
|
||||
* @copyright (C) Adam Armstrong
|
||||
*
|
||||
*/
|
||||
|
||||
$ds_in = "read";
|
||||
$ds_in = "read";
|
||||
$ds_out = "written";
|
||||
|
||||
$format = "bytes";
|
||||
|
||||
include($config['html_dir']."/includes/graphs/generic_data.inc.php");
|
||||
include($config['html_dir'] . "/includes/graphs/generic_data.inc.php");
|
||||
|
||||
?>
|
||||
|
@ -5,27 +5,27 @@
|
||||
*
|
||||
* This file is part of Observium.
|
||||
*
|
||||
* @package observium
|
||||
* @subpackage graphs
|
||||
* @copyright (C) 2006-2013 Adam Armstrong, (C) 2013-2019 Observium Limited
|
||||
* @package observium
|
||||
* @subpackage graphs
|
||||
* @copyright (C) Adam Armstrong
|
||||
*
|
||||
*/
|
||||
|
||||
$ds_in = "reads";
|
||||
$ds_in = "reads";
|
||||
$ds_out = "writes";
|
||||
|
||||
$colour_area_in = "FF3300";
|
||||
$colour_line_in = "FF0000";
|
||||
$colour_area_in = "FF3300";
|
||||
$colour_line_in = "FF0000";
|
||||
$colour_area_out = "FF6633";
|
||||
$colour_line_out = "CC3300";
|
||||
|
||||
$colour_area_in_max = "FF6633";
|
||||
$colour_area_in_max = "FF6633";
|
||||
$colour_area_out_max = "FF9966";
|
||||
|
||||
$graph_max = 1;
|
||||
|
||||
$unit_text = "Ops/sec";
|
||||
|
||||
include($config['html_dir']."/includes/graphs/generic_duplex.inc.php");
|
||||
include($config['html_dir'] . "/includes/graphs/generic_duplex.inc.php");
|
||||
|
||||
?>
|
||||
|
@ -4,7 +4,7 @@ $scale_min = "0";
|
||||
|
||||
$rrd_filename = get_rrd_path($device, "diskstat-" . $disk['diskio_descr'] . ".rrd");
|
||||
|
||||
include($config['html_dir']."/includes/graphs/common.inc.php");
|
||||
include($config['html_dir'] . "/includes/graphs/common.inc.php");
|
||||
|
||||
$rrd_options .= " DEF:read=$rrd_filename_escape:readcount:AVERAGE";
|
||||
$rrd_options .= " DEF:timeread=$rrd_filename_escape:time_reading:AVERAGE";
|
||||
@ -25,16 +25,16 @@ $rrd_options .= " GPRINT:b:AVERAGE:' %6.2lf'";
|
||||
$rrd_options .= " GPRINT:b:MAX:' %6.2lf\\n'";
|
||||
|
||||
/**
|
||||
$rrd_options .= " AREA:timeread#ffeeaa:'timeread'";
|
||||
$rrd_options .= " LINE1:timeread#c5aa00:";
|
||||
$rrd_options .= " GPRINT:timeread:LAST:' %6.2lf'";
|
||||
$rrd_options .= " GPRINT:timeread:AVERAGE:' %6.2lf'";
|
||||
$rrd_options .= " GPRINT:timeread:MAX:' %6.2lf\\n'";
|
||||
$rrd_options .= " AREA:read#ffeeaa:'read'";
|
||||
$rrd_options .= " LINE1:read#c5aa00:";
|
||||
$rrd_options .= " GPRINT:read:LAST:' %6.2lf'";
|
||||
$rrd_options .= " GPRINT:read:AVERAGE:' %6.2lf'";
|
||||
$rrd_options .= " GPRINT:read:MAX:' %6.2lf\\n'";
|
||||
**/
|
||||
* $rrd_options .= " AREA:timeread#ffeeaa:'timeread'";
|
||||
* $rrd_options .= " LINE1:timeread#c5aa00:";
|
||||
* $rrd_options .= " GPRINT:timeread:LAST:' %6.2lf'";
|
||||
* $rrd_options .= " GPRINT:timeread:AVERAGE:' %6.2lf'";
|
||||
* $rrd_options .= " GPRINT:timeread:MAX:' %6.2lf\\n'";
|
||||
* $rrd_options .= " AREA:read#ffeeaa:'read'";
|
||||
* $rrd_options .= " LINE1:read#c5aa00:";
|
||||
* $rrd_options .= " GPRINT:read:LAST:' %6.2lf'";
|
||||
* $rrd_options .= " GPRINT:read:AVERAGE:' %6.2lf'";
|
||||
* $rrd_options .= " GPRINT:read:MAX:' %6.2lf\\n'";
|
||||
**/
|
||||
|
||||
?>
|
||||
|
Reference in New Issue
Block a user