From cd94ef34134d8f06af83ec97119018b4e80346a0 Mon Sep 17 00:00:00 2001 From: Pim van den Berg Date: Sun, 20 Sep 2009 13:36:25 +0200 Subject: initial import of cgp Collectd Graph Panel is a frontend for Collectd written in PHP. The goal of CGP is to provide an easy-to-use frontend for Collectd, starting with page that shows an overview of all the hosts you are managing with Collectd. In this initial import there is support for the plugins that are default enabled in Collectd. The supported plugins are located in the plugin directory. --- plugin/users.php | 37 +++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 plugin/users.php (limited to 'plugin/users.php') diff --git a/plugin/users.php b/plugin/users.php new file mode 100644 index 0000000..dfcaee3 --- /dev/null +++ b/plugin/users.php @@ -0,0 +1,37 @@ +datadir = $CONFIG['datadir']; +$obj->path_format = '{host}/{plugin}/{type}.rrd'; +$obj->args = array( + 'host' => $host, + 'plugin' => $plugin, + 'pinstance' => $pinstance, + 'type' => $type, + 'tinstance' => $tinstance, +); +$obj->data_sources = array('users'); +$obj->ds_names = array( + 'users' => 'Users', +); +$obj->colors = array( + 'users' => '0000f0', +); +$obj->width = $width; +$obj->heigth = $heigth; +$obj->seconds = $seconds; +$obj->rrd_title = "Users on $host"; +$obj->rrd_vertical = 'Users'; +$obj->rrd_format = '%.1lf'; + +$obj->rrd_graph(); + +?> -- cgit v1.1