2017-04-28 23:48:26 +02:00
|
|
|
<?php
|
|
|
|
|
/*
|
|
|
|
|
* This program is free software: you can redistribute it and/or modify it
|
|
|
|
|
* under the terms of the GNU General Public License as published by the
|
|
|
|
|
* Free Software Foundation, either version 3 of the License, or (at your
|
|
|
|
|
* option) any later version. Please see LICENSE.txt at the top level of
|
|
|
|
|
* the source code distribution for details.
|
|
|
|
|
*
|
|
|
|
|
* @package LibreNMS
|
|
|
|
|
* @subpackage nfs-server
|
2021-02-09 00:29:04 +01:00
|
|
|
* @link https://www.librenms.org
|
2017-04-28 23:48:26 +02:00
|
|
|
* @copyright 2017 LibreNMS
|
|
|
|
|
* @author SvennD <svennd@svennd.be>
|
|
|
|
|
*/
|
|
|
|
|
|
2019-04-11 23:26:42 -05:00
|
|
|
require 'includes/html/graphs/common.inc.php';
|
2017-04-28 23:48:26 +02:00
|
|
|
$scale_min = 0;
|
|
|
|
|
$colours = 'mixed';
|
2017-07-05 21:20:30 +02:00
|
|
|
$unit_text = 'v3 write operations';
|
2017-04-28 23:48:26 +02:00
|
|
|
$unitlen = 10;
|
|
|
|
|
$bigdescrlen = 15;
|
|
|
|
|
$smalldescrlen = 15;
|
|
|
|
|
$dostack = 0;
|
|
|
|
|
$printtotal = 0;
|
|
|
|
|
$addarea = 1;
|
|
|
|
|
$transparency = 33;
|
|
|
|
|
|
2022-07-22 16:01:55 -05:00
|
|
|
$rrd_filename = Rrd::name($device['hostname'], ['app', 'nfs-server-proc3', $app->app_id]);
|
2017-04-28 23:48:26 +02:00
|
|
|
|
|
|
|
|
$array = [
|
|
|
|
|
'proc3_setattr' => ['descr' => 'Set attributes'],
|
|
|
|
|
'proc3_create' => ['descr' => 'Create'],
|
|
|
|
|
'proc3_mkdir' => ['descr' => 'Make dir'],
|
|
|
|
|
'proc3_mknod' => ['descr' => 'Make nod'],
|
|
|
|
|
'proc3_link' => ['descr' => 'Link'],
|
|
|
|
|
'proc3_remove' => ['descr' => 'Remove'],
|
|
|
|
|
'proc3_rmdir' => ['descr' => 'Remove dir'],
|
|
|
|
|
'proc3_rename' => ['descr' => 'Rename'],
|
|
|
|
|
'proc3_symlink' => ['descr' => 'Symlink'],
|
|
|
|
|
'proc3_commit' => ['descr' => 'Commit'],
|
|
|
|
|
];
|
|
|
|
|
|
|
|
|
|
$i = 0;
|
|
|
|
|
|
2021-03-28 17:25:30 -05:00
|
|
|
if (Rrd::checkRrdExists($rrd_filename)) {
|
2017-04-28 23:48:26 +02:00
|
|
|
foreach ($array as $ds => $var) {
|
|
|
|
|
$rrd_list[$i]['filename'] = $rrd_filename;
|
|
|
|
|
$rrd_list[$i]['descr'] = $var['descr'];
|
|
|
|
|
$rrd_list[$i]['ds'] = $ds;
|
2019-06-23 00:29:12 -05:00
|
|
|
$rrd_list[$i]['colour'] = \LibreNMS\Config::get("graph_colours.$colours.$i");
|
2017-04-28 23:48:26 +02:00
|
|
|
$i++;
|
|
|
|
|
}
|
|
|
|
|
} else {
|
|
|
|
|
echo "file missing: $rrd_filename";
|
|
|
|
|
}
|
|
|
|
|
|
2019-04-11 23:26:42 -05:00
|
|
|
require 'includes/html/graphs/generic_v3_multiline.inc.php';
|