aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/plugin/zfs_arc.php
diff options
context:
space:
mode:
authorPim van den Berg2012-09-05 16:07:44 +0200
committerPim van den Berg2012-09-05 16:10:39 +0200
commit074589c36937a468587abe37bc4ce0fbddf80b20 (patch)
tree921ffd1e49dde8bd21f625409f12d70251f3204b /plugin/zfs_arc.php
parentplugin: add snmp plugin (diff)
downloadapt-panopticon_cgp-074589c36937a468587abe37bc4ce0fbddf80b20.zip
apt-panopticon_cgp-074589c36937a468587abe37bc4ce0fbddf80b20.tar.gz
apt-panopticon_cgp-074589c36937a468587abe37bc4ce0fbddf80b20.tar.bz2
apt-panopticon_cgp-074589c36937a468587abe37bc4ce0fbddf80b20.tar.xz
apply datasize (bytes/bits) only to network related data
As discussed in https://github.com/pommi/CGP/pull/1.
Diffstat (limited to '')
-rw-r--r--plugin/zfs_arc.php11
1 files changed, 4 insertions, 7 deletions
diff --git a/plugin/zfs_arc.php b/plugin/zfs_arc.php
index 1cc7e81..d40912d 100644
--- a/plugin/zfs_arc.php
+++ b/plugin/zfs_arc.php
@@ -60,8 +60,7 @@ switch($obj->args['type']) {
60 'maxlimit', 60 'maxlimit',
61 ); 61 );
62 $obj->rrd_title = 'Arc size'; 62 $obj->rrd_title = 'Arc size';
63 $obj->rrd_vertical = ucfirst($CONFIG['datasize']); 63 $obj->rrd_vertical = 'bytes';
64 $obj->scale = $CONFIG['datasize'] == 'bits' ? 8 : 1;
65 break; 64 break;
66 case 'arc_l2_bytes': 65 case 'arc_l2_bytes':
67 $obj->data_sources = array( 66 $obj->data_sources = array(
@@ -77,22 +76,20 @@ switch($obj->args['type']) {
77 'read' => '0000ff', 76 'read' => '0000ff',
78 ); 77 );
79 $obj->rrd_title = 'Arc L2 bytes'; 78 $obj->rrd_title = 'Arc L2 bytes';
80 $obj->rrd_vertical = ucfirst($CONFIG['datasize']); 79 $obj->rrd_vertical = 'bytes';
81 $obj->scale = $CONFIG['datasize'] == 'bits' ? 8 : 1;
82 break; 80 break;
83 case 'arc_l2_size': 81 case 'arc_l2_size':
84 $obj->data_sources = array( 82 $obj->data_sources = array(
85 'value', 83 'value',
86 ); 84 );
87 $obj->ds_names = array( 85 $obj->ds_names = array(
88 'value' => ucfirst($CONFIG['datasize']), 86 'value' => 'Bytes',
89 ); 87 );
90 $obj->colors = array( 88 $obj->colors = array(
91 'value' => '0000ff', 89 'value' => '0000ff',
92 ); 90 );
93 $obj->rrd_title = 'Arc L2 size'; 91 $obj->rrd_title = 'Arc L2 size';
94 $obj->rrd_vertical = ucfirst($CONFIG['datasize']); 92 $obj->rrd_vertical = 'bytes';
95 $obj->scale = $CONFIG['datasize'] == 'bits' ? 8 : 1;
96 break; 93 break;
97 case 'arc_ratio': 94 case 'arc_ratio':
98 $obj->data_sources = array('value'); 95 $obj->data_sources = array('value');