aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/plugin/swap.php
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--plugin/swap.php50
1 files changed, 0 insertions, 50 deletions
diff --git a/plugin/swap.php b/plugin/swap.php
deleted file mode 100644
index 140772c..0000000
--- a/plugin/swap.php
+++ /dev/null
@@ -1,50 +0,0 @@
1<?php
2
3# Collectd Swap plugin
4
5require_once 'conf/common.inc.php';
6
7## LAYOUT
8# swap/
9# swap/swap-cached.rrd
10# swap/swap-free.rrd
11# swap/swap-used.rrd
12
13switch(GET('t')) {
14 case 'swap':
15 require_once 'type/GenericStacked.class.php';
16 $obj = new Type_GenericStacked($CONFIG, $_GET);
17 $obj->order = array('free', 'cached', 'used');
18 $obj->legend = array(
19 'free' => 'Free',
20 'cached' => 'Cached',
21 'used' => 'Used',
22 );
23 $obj->colors = array(
24 'free' => '00e000',
25 'cached' => '0000ff',
26 'used' => 'ff0000',
27 );
28 $obj->rrd_title = 'Swap utilization';
29 $obj->rrd_vertical = 'Bytes';
30 break;
31 case 'swap_io':
32 require_once 'type/GenericIO.class.php';
33 $obj = new Type_GenericIO($CONFIG, $_GET);
34 $obj->order = array('out', 'in');
35 $obj->legend = array(
36 'out' => 'Out',
37 'in' => 'In',
38 );
39 $obj->colors = array(
40 'out' => '0000ff',
41 'in' => '00b000',
42 );
43 $obj->rrd_title = 'Swapped I/O pages';
44 $obj->rrd_vertical = 'Pages';
45 break;
46}
47
48$obj->rrd_format = '%5.1lf%s';
49
50$obj->rrd_graph();