aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorPim van den Berg2010-09-15 19:00:35 +0200
committerPim van den Berg2010-09-15 19:02:14 +0200
commit589111dddb1329b08c03ecc54ab3e97ff742f9f4 (patch)
tree9a38331b84b5113fd0cb117f038437d6103ef8c3
parentplugin/nfs: remove ds_names to keep it simple (diff)
downloadapt-panopticon_cgp-589111dddb1329b08c03ecc54ab3e97ff742f9f4.zip
apt-panopticon_cgp-589111dddb1329b08c03ecc54ab3e97ff742f9f4.tar.gz
apt-panopticon_cgp-589111dddb1329b08c03ecc54ab3e97ff742f9f4.tar.bz2
apt-panopticon_cgp-589111dddb1329b08c03ecc54ab3e97ff742f9f4.tar.xz
plugin/nfs: clean up some duplicate code
-rw-r--r--plugin/nfs.php7
1 files changed, 2 insertions, 5 deletions
diff --git a/plugin/nfs.php b/plugin/nfs.php
index be131c2..24a61a8 100644
--- a/plugin/nfs.php
+++ b/plugin/nfs.php
@@ -17,23 +17,20 @@ $obj->data_sources = array('value');
17switch($obj->args['pinstance']) { 17switch($obj->args['pinstance']) {
18 case 'v2client': 18 case 'v2client':
19 $obj->order = array('create', 'fsstat', 'getattr', 'link', 'lookup', 'mkdir', 'null', 'readdir', 'readlink', 'read', 'remove', 'rename', 'rmdir', 'root', 'setattr', 'symlink', 'wrcache', 'write'); 19 $obj->order = array('create', 'fsstat', 'getattr', 'link', 'lookup', 'mkdir', 'null', 'readdir', 'readlink', 'read', 'remove', 'rename', 'rmdir', 'root', 'setattr', 'symlink', 'wrcache', 'write');
20 $obj->generate_colors();
21 break; 20 break;
22 21
23 case 'v3client': 22 case 'v3client':
24 $obj->order = array('access', 'commit', 'create', 'fsinfo', 'fsstat', 'getattr', 'link', 'lookup', 'mkdir', 'mknod', 'null', 'pathconf', 'read', 'readdir', 'readdirplus', 'readlink', 'remove', 'rename', 'rmdir', 'setattr', 'symlink', 'write'); 23 $obj->order = array('access', 'commit', 'create', 'fsinfo', 'fsstat', 'getattr', 'link', 'lookup', 'mkdir', 'mknod', 'null', 'pathconf', 'read', 'readdir', 'readdirplus', 'readlink', 'remove', 'rename', 'rmdir', 'setattr', 'symlink', 'write');
25 $obj->generate_colors();
26
27 break; 24 break;
28
29
30} 25}
26
31$obj->width = $width; 27$obj->width = $width;
32$obj->heigth = $heigth; 28$obj->heigth = $heigth;
33 29
34$obj->rrd_title = sprintf('NFS-%s Procedures', $obj->args['pinstance']); 30$obj->rrd_title = sprintf('NFS-%s Procedures', $obj->args['pinstance']);
35$obj->rrd_vertical = 'Procedures'; 31$obj->rrd_vertical = 'Procedures';
36$obj->rrd_format = '%5.2lf'; 32$obj->rrd_format = '%5.2lf';
33$obj->generate_colors();
37 34
38collectd_flush($obj->identifiers); 35collectd_flush($obj->identifiers);
39$obj->rrd_graph(); 36$obj->rrd_graph();