From a9e38121fdfce63a82da3b4d0177b9bdc485b1c9 Mon Sep 17 00:00:00 2001 From: Tomas Barton Date: Wed, 21 Aug 2013 17:33:24 +0200 Subject: README converted to MarkDown syntax --- README.md | 82 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 82 insertions(+) create mode 100644 README.md (limited to 'README.md') diff --git a/README.md b/README.md new file mode 100644 index 0000000..1a46be2 --- /dev/null +++ b/README.md @@ -0,0 +1,82 @@ +# Munin + +Munin is a performance monitoring system which creates nice RRD graphs and has +a very easy plugin interface. The munin homepage is http://munin.projects.linpro.no/ + +To use this module, follow these directions: + +## Requirements + + * puppet 2.7 or newer + * install the `common`, `concat` and `stdlib` modules -- the munin module depends on functions that are defined and installed via these modules + * you will need storedconfigs enabled in your puppet setup, to do that you need to add a line to your `puppet.conf` in your `[puppetmasterd]` section which says: + + storeconfigs=true + + * You may wish to immediately setup a `mysql`/ `pgsql` database for your storedconfigs, as + the default method uses sqlite, and is not very efficient, to do that you need lines + such as the following below the `storeconfigs=true` line (adjust as needed): + + dbadapter=mysql + dbserver=localhost + dbuser=puppet + dbpassword=puppetspasswd + +## Usage + + a. Your modules directory will need all the files included in this repository placed + under a directory called "munin" + + b. For every host you wish to gather munin statistics, add the class munin::client to that + node. You will want to set the class parameter 'allow' to be the IP(s) of the munin + collector, this defines what IP is permitted to connect to the node, for example: + + node foo { + class { 'munin::client': allow => '192.168.0.1'} + } + + +for multiple munin nodes, you can pass an array: + + class { 'munin::client': allow => [ '192.168.0.1', '10.0.0.1' ] } + + c. In the node definition in your site.pp for your main munin host, add the following: + + class { 'munin::host': } + + If you want cgi graphing you can pass cgi_graphing => true. + (For CentOS this is enabled in the default header config) + for more information, see: http://munin.projects.linpro.no/wiki/CgiHowto + + d. If there are particular munin plugins you want to enable or configure, you define them + in the node definition, like follows: + + # Enable monitoring of disk stats in bytes + munin::plugin { 'df_abs': } + + # Use a non-standard plugin path to use custom plugins + munin::plugin { 'spamassassin': + ensure => present, + script_path => '/usr/local/share/munin-plugins', + } + + # For wildcard plugins (eg. ip_, snmp_, etc.), use the name variable to + # configure the plugin name, and the ensure parameter to indicate the base + # plugin name to which you want a symlink, for example: + munin::plugin { [ 'ip_192.168.0.1', 'ip_10.0.0.1' ]: + ensure => 'ip_' + } + + # Use a special config to pass parameters to the plugin + munin::plugin { + [ 'apache_accesses', 'apache_processes', 'apache_volume' ]: + ensure => present, + config => 'env.url http://127.0.0.1:80/server-status?auto' + } + + e. If you have Linux-Vservers configured, you will likely have multiple munin-node processes + competing for the default port 4949, for those nodes, set an alternate port for munin-node + to run on by putting something similar to the following class parameter: + + class { 'munin::client': allow => '192.168.0.1', port => '4948' } + -- cgit v1.2.3 From 8f8ef21afd6424fc7f6ecaabb968b8278073d430 Mon Sep 17 00:00:00 2001 From: Tomas Barton Date: Wed, 21 Aug 2013 17:35:46 +0200 Subject: lists formatting --- README.md | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) (limited to 'README.md') diff --git a/README.md b/README.md index 1a46be2..d6347ee 100644 --- a/README.md +++ b/README.md @@ -1,10 +1,8 @@ -# Munin +# Puppet-Munin Munin is a performance monitoring system which creates nice RRD graphs and has a very easy plugin interface. The munin homepage is http://munin.projects.linpro.no/ -To use this module, follow these directions: - ## Requirements * puppet 2.7 or newer @@ -24,10 +22,10 @@ To use this module, follow these directions: ## Usage - a. Your modules directory will need all the files included in this repository placed + 1. Your modules directory will need all the files included in this repository placed under a directory called "munin" - b. For every host you wish to gather munin statistics, add the class munin::client to that + 2. For every host you wish to gather munin statistics, add the class munin::client to that node. You will want to set the class parameter 'allow' to be the IP(s) of the munin collector, this defines what IP is permitted to connect to the node, for example: @@ -40,7 +38,7 @@ for multiple munin nodes, you can pass an array: class { 'munin::client': allow => [ '192.168.0.1', '10.0.0.1' ] } - c. In the node definition in your site.pp for your main munin host, add the following: + 3. In the node definition in your site.pp for your main munin host, add the following: class { 'munin::host': } @@ -48,7 +46,7 @@ for multiple munin nodes, you can pass an array: (For CentOS this is enabled in the default header config) for more information, see: http://munin.projects.linpro.no/wiki/CgiHowto - d. If there are particular munin plugins you want to enable or configure, you define them + 4. If there are particular munin plugins you want to enable or configure, you define them in the node definition, like follows: # Enable monitoring of disk stats in bytes @@ -74,7 +72,7 @@ for multiple munin nodes, you can pass an array: config => 'env.url http://127.0.0.1:80/server-status?auto' } - e. If you have Linux-Vservers configured, you will likely have multiple munin-node processes + 5. If you have Linux-Vservers configured, you will likely have multiple munin-node processes competing for the default port 4949, for those nodes, set an alternate port for munin-node to run on by putting something similar to the following class parameter: -- cgit v1.2.3 From 67af1c2b32e4557cc9b62d1b8046bb6c2b006319 Mon Sep 17 00:00:00 2001 From: Tomas Barton Date: Wed, 21 Aug 2013 17:38:02 +0200 Subject: fixed list numbering --- README.md | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) (limited to 'README.md') diff --git a/README.md b/README.md index d6347ee..74d82ba 100644 --- a/README.md +++ b/README.md @@ -26,15 +26,14 @@ a very easy plugin interface. The munin homepage is http://munin.projects.linpro under a directory called "munin" 2. For every host you wish to gather munin statistics, add the class munin::client to that - node. You will want to set the class parameter 'allow' to be the IP(s) of the munin + node. You will want to set the class parameter `allow` to be the IP(s) of the munin collector, this defines what IP is permitted to connect to the node, for example: node foo { class { 'munin::client': allow => '192.168.0.1'} } - -for multiple munin nodes, you can pass an array: + for multiple munin nodes, you can pass an array: class { 'munin::client': allow => [ '192.168.0.1', '10.0.0.1' ] } @@ -42,9 +41,7 @@ for multiple munin nodes, you can pass an array: class { 'munin::host': } - If you want cgi graphing you can pass cgi_graphing => true. - (For CentOS this is enabled in the default header config) - for more information, see: http://munin.projects.linpro.no/wiki/CgiHowto + If you want cgi graphing you can pass `cgi_graphing => true`. (For CentOS this is enabled in the default header config) for more information, see: http://munin.projects.linpro.no/wiki/CgiHowto 4. If there are particular munin plugins you want to enable or configure, you define them in the node definition, like follows: -- cgit v1.2.3 From eed532c8bbf4a6ed63b53a03b91ebf26ff14e7a0 Mon Sep 17 00:00:00 2001 From: mh Date: Sun, 25 Aug 2013 13:05:37 +0200 Subject: there isn't anymore any dependency on the common module --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'README.md') diff --git a/README.md b/README.md index 74d82ba..0ab9c86 100644 --- a/README.md +++ b/README.md @@ -6,7 +6,7 @@ a very easy plugin interface. The munin homepage is http://munin.projects.linpro ## Requirements * puppet 2.7 or newer - * install the `common`, `concat` and `stdlib` modules -- the munin module depends on functions that are defined and installed via these modules + * install the `concat` and `stdlib` modules -- the munin module depends on functions that are defined and installed via these modules * you will need storedconfigs enabled in your puppet setup, to do that you need to add a line to your `puppet.conf` in your `[puppetmasterd]` section which says: storeconfigs=true -- cgit v1.2.3 From 5a2711037a2fc016666ca75e5fbec69d5009b9d8 Mon Sep 17 00:00:00 2001 From: Tomas Barton Date: Tue, 3 Sep 2013 23:41:07 +0200 Subject: plugin::deploy added to README --- README.md | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'README.md') diff --git a/README.md b/README.md index 0ab9c86..71b935e 100644 --- a/README.md +++ b/README.md @@ -8,7 +8,7 @@ a very easy plugin interface. The munin homepage is http://munin.projects.linpro * puppet 2.7 or newer * install the `concat` and `stdlib` modules -- the munin module depends on functions that are defined and installed via these modules * you will need storedconfigs enabled in your puppet setup, to do that you need to add a line to your `puppet.conf` in your `[puppetmasterd]` section which says: - + storeconfigs=true * You may wish to immediately setup a `mysql`/ `pgsql` database for your storedconfigs, as @@ -75,3 +75,11 @@ a very easy plugin interface. The munin homepage is http://munin.projects.linpro class { 'munin::client': allow => '192.168.0.1', port => '4948' } + 6. For deploying plugins which are not available at client, you can fetch them from puppet + master using `munin::plugin::deploy`. + + munin::plugin::deploy { 'redis': + source => 'munin/plugins/redis/redis_', + } + + In this case the file on master would be located in `/etc/puppet/modules/munin/files/plugins/redis/redis_` \ No newline at end of file -- cgit v1.2.3 From e6a975eb0ab7ef99479344b553ac2431555f5747 Mon Sep 17 00:00:00 2001 From: Tomas Barton Date: Thu, 5 Sep 2013 10:01:44 +0200 Subject: mentioned modulepath where puppet searches for plugins to deploy --- README.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'README.md') diff --git a/README.md b/README.md index 71b935e..9e4602e 100644 --- a/README.md +++ b/README.md @@ -80,6 +80,9 @@ a very easy plugin interface. The munin homepage is http://munin.projects.linpro munin::plugin::deploy { 'redis': source => 'munin/plugins/redis/redis_', + config => '' # pass parameters to plugin } - In this case the file on master would be located in `/etc/puppet/modules/munin/files/plugins/redis/redis_` \ No newline at end of file + In this example the file on master would be located in `{modulepath}/munin/files/plugins/redis/redis_`. + Module path is specified in `puppet.conf`, you can find out your `{modulepath}` easily by tying + in console `puppet config print modulepath`. \ No newline at end of file -- cgit v1.2.3 From 2f2627cd49c93f7455b2e6294e11e16be99a27ac Mon Sep 17 00:00:00 2001 From: Tomas Barton Date: Sat, 7 Sep 2013 10:20:18 +0200 Subject: readme reformatted into sections Conflicts: README.md --- README.md | 123 +++++++++++++++++++++++++++++++++++--------------------------- 1 file changed, 70 insertions(+), 53 deletions(-) (limited to 'README.md') diff --git a/README.md b/README.md index 9e4602e..b7f75fc 100644 --- a/README.md +++ b/README.md @@ -6,7 +6,7 @@ a very easy plugin interface. The munin homepage is http://munin.projects.linpro ## Requirements * puppet 2.7 or newer - * install the `concat` and `stdlib` modules -- the munin module depends on functions that are defined and installed via these modules + * install the `concat` and `stdlib` modules - the munin module depends on functions that are defined and installed via these modules * you will need storedconfigs enabled in your puppet setup, to do that you need to add a line to your `puppet.conf` in your `[puppetmasterd]` section which says: storeconfigs=true @@ -22,67 +22,84 @@ a very easy plugin interface. The munin homepage is http://munin.projects.linpro ## Usage - 1. Your modules directory will need all the files included in this repository placed - under a directory called "munin" +Your modules directory will need all the files included in this repository placed under a directory called `munin`. - 2. For every host you wish to gather munin statistics, add the class munin::client to that - node. You will want to set the class parameter `allow` to be the IP(s) of the munin - collector, this defines what IP is permitted to connect to the node, for example: +### Master configuration - node foo { - class { 'munin::client': allow => '192.168.0.1'} - } +In the node definition in your site.pp for your main munin host, add the following: - for multiple munin nodes, you can pass an array: + class { 'munin::host': } - class { 'munin::client': allow => [ '192.168.0.1', '10.0.0.1' ] } +If you want cgi graphing you can pass `cgi_graphing => true`. (For CentOS this is enabled in the default header config) for more information, see: http://munin.projects.linpro.no/wiki/CgiHowto + +### Client configuration + +For every host you wish to gather munin statistics, add the class `munin::client` to that +node. You will want to set the class parameter `allow` to be the IP(s) of the munin +collector, this defines what IP is permitted to connect to the node, for example: + + node foo { + class { 'munin::client': allow => '192.168.0.1'} + } + +for multiple munin nodes, you can pass an array: + + class { 'munin::client': allow => [ '192.168.0.1', '10.0.0.1' ] } 3. In the node definition in your site.pp for your main munin host, add the following: - class { 'munin::host': } - - If you want cgi graphing you can pass `cgi_graphing => true`. (For CentOS this is enabled in the default header config) for more information, see: http://munin.projects.linpro.no/wiki/CgiHowto +### Local plugins - 4. If there are particular munin plugins you want to enable or configure, you define them - in the node definition, like follows: +If there are particular munin plugins you want to enable or configure, you define them +in the node definition, like follows: - # Enable monitoring of disk stats in bytes - munin::plugin { 'df_abs': } + # Enable monitoring of disk stats in bytes + munin::plugin { 'df_abs': } - # Use a non-standard plugin path to use custom plugins - munin::plugin { 'spamassassin': - ensure => present, - script_path => '/usr/local/share/munin-plugins', - } + # Use a non-standard plugin path to use custom plugins + munin::plugin { 'spamassassin': + ensure => present, + script_path => '/usr/local/share/munin-plugins', + } - # For wildcard plugins (eg. ip_, snmp_, etc.), use the name variable to - # configure the plugin name, and the ensure parameter to indicate the base - # plugin name to which you want a symlink, for example: - munin::plugin { [ 'ip_192.168.0.1', 'ip_10.0.0.1' ]: - ensure => 'ip_' - } + # For wildcard plugins (eg. ip_, snmp_, etc.), use the name variable to + # configure the plugin name, and the ensure parameter to indicate the base + # plugin name to which you want a symlink, for example: + munin::plugin { [ 'ip_192.168.0.1', 'ip_10.0.0.1' ]: + ensure => 'ip_' + } - # Use a special config to pass parameters to the plugin - munin::plugin { - [ 'apache_accesses', 'apache_processes', 'apache_volume' ]: - ensure => present, - config => 'env.url http://127.0.0.1:80/server-status?auto' - } - - 5. If you have Linux-Vservers configured, you will likely have multiple munin-node processes - competing for the default port 4949, for those nodes, set an alternate port for munin-node - to run on by putting something similar to the following class parameter: - - class { 'munin::client': allow => '192.168.0.1', port => '4948' } - - 6. For deploying plugins which are not available at client, you can fetch them from puppet - master using `munin::plugin::deploy`. - - munin::plugin::deploy { 'redis': - source => 'munin/plugins/redis/redis_', - config => '' # pass parameters to plugin - } - - In this example the file on master would be located in `{modulepath}/munin/files/plugins/redis/redis_`. - Module path is specified in `puppet.conf`, you can find out your `{modulepath}` easily by tying - in console `puppet config print modulepath`. \ No newline at end of file + # Use a special config to pass parameters to the plugin + munin::plugin { + [ 'apache_accesses', 'apache_processes', 'apache_volume' ]: + ensure => present, + config => 'env.url http://127.0.0.1:80/server-status?auto' + } + +Note: The plugin must be installed at the client. For listing available plugins run as root `munin-node-configure --suggest` + +### External plugins + +For deploying plugins which are not available at client, you can fetch them from puppet +master using `munin::plugin::deploy`. + + munin::plugin::deploy { 'redis': + source => 'munin/plugins/redis/redis_', + config => '' # pass parameters to plugin + } + +In this example the file on master would be located in: + + {modulepath}/munin/files/plugins/redis/redis_ + +Module path is specified in `puppet.conf`, you can find out your `{modulepath}` easily by tying +in console `puppet config print modulepath`. + + +### Multiple munin instances + +If you have Linux-Vservers configured, you will likely have multiple munin-node processes +competing for the default port 4949, for those nodes, set an alternate port for munin-node +to run on by putting something similar to the following class parameter: + + class { 'munin::client': allow => '192.168.0.1', port => '4948' } -- cgit v1.2.3 From 7cd45bebbf2eea216bbc34765e68bcb36b540593 Mon Sep 17 00:00:00 2001 From: Kondrashov Ilia Date: Sat, 5 Oct 2013 21:03:53 +0400 Subject: Correct script_path_in param name --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'README.md') diff --git a/README.md b/README.md index b7f75fc..420277e 100644 --- a/README.md +++ b/README.md @@ -58,8 +58,8 @@ in the node definition, like follows: # Use a non-standard plugin path to use custom plugins munin::plugin { 'spamassassin': - ensure => present, - script_path => '/usr/local/share/munin-plugins', + ensure => present, + script_path_in => '/usr/local/share/munin-plugins', } # For wildcard plugins (eg. ip_, snmp_, etc.), use the name variable to -- cgit v1.2.3 From 8a1540cedc4d5726bb9511d9fa291b56414746ca Mon Sep 17 00:00:00 2001 From: Tomas Barton Date: Mon, 14 Oct 2013 11:23:32 +0200 Subject: enable travis-ci integration --- README.md | 2 ++ 1 file changed, 2 insertions(+) (limited to 'README.md') diff --git a/README.md b/README.md index 420277e..9c5474f 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,7 @@ # Puppet-Munin +[![Build Status](https://travis-ci.org/duritong/puppet-munin.png?branch=master)](https://travis-ci.org/duritong/puppet-munin) + Munin is a performance monitoring system which creates nice RRD graphs and has a very easy plugin interface. The munin homepage is http://munin.projects.linpro.no/ -- cgit v1.2.3 From eaa092eb1a8f3ae19551e6e80f84d174211b5208 Mon Sep 17 00:00:00 2001 From: Gabriel Filion Date: Sat, 13 Dec 2014 11:49:14 -0500 Subject: update readme to use the new "main" class --- README.md | 53 +++++++++++++++++++++++++++++++++++++++++++---------- 1 file changed, 43 insertions(+), 10 deletions(-) (limited to 'README.md') diff --git a/README.md b/README.md index 9c5474f..db6af95 100644 --- a/README.md +++ b/README.md @@ -28,27 +28,25 @@ Your modules directory will need all the files included in this repository place ### Master configuration -In the node definition in your site.pp for your main munin host, add the following: +To install a master (or server) you need to flip one argument to true in the main class: - class { 'munin::host': } + class { 'munin': is_server => true } If you want cgi graphing you can pass `cgi_graphing => true`. (For CentOS this is enabled in the default header config) for more information, see: http://munin.projects.linpro.no/wiki/CgiHowto ### Client configuration -For every host you wish to gather munin statistics, add the class `munin::client` to that +For every host you wish to gather munin statistics, add the class `munin` to that node. You will want to set the class parameter `allow` to be the IP(s) of the munin collector, this defines what IP is permitted to connect to the node, for example: node foo { - class { 'munin::client': allow => '192.168.0.1'} + class { 'munin': allow => '192.168.0.1'} } -for multiple munin nodes, you can pass an array: +for multiple munin collectors, you can pass an array: - class { 'munin::client': allow => [ '192.168.0.1', '10.0.0.1' ] } - - 3. In the node definition in your site.pp for your main munin host, add the following: + class { 'munin': allow => [ '192.168.0.1', '10.0.0.1' ] } ### Local plugins @@ -98,10 +96,45 @@ Module path is specified in `puppet.conf`, you can find out your `{modulepath}` in console `puppet config print modulepath`. -### Multiple munin instances +### Multiple munin collectors + +If some part of your infrastructure should be graphed by one munin collector, +and another part by a second collector, you can use the parameter $export_tag +to the main class to differentiate which clients and collectors are associated. + +For example, here are four nodes: two collectors and two clients. Each +collector is associated with one client: + + node coll1 { + class { 'munin': + $is_server => true, + $export_tag => 'coll1', + } + } + + node client1 { + class { 'munin': + $export_tag => 'coll1', + } + } + + node coll2 { + class { 'munin': + $is_server => true, + $export_tag => 'coll2', + } + } + + node client2 { + class { 'munin': + $export_tag => 'coll2', + } + } + +### Multiple munin-node instances with Linux-VServer If you have Linux-Vservers configured, you will likely have multiple munin-node processes competing for the default port 4949, for those nodes, set an alternate port for munin-node to run on by putting something similar to the following class parameter: - class { 'munin::client': allow => '192.168.0.1', port => '4948' } + class { 'munin': allow => '192.168.0.1', port => '4948' } -- cgit v1.2.3 From 633b8083d23011668735823dff4c5af2d491aa0c Mon Sep 17 00:00:00 2001 From: Gabriel Filion Date: Fri, 14 Aug 2015 05:01:32 -0400 Subject: Add an upgrade notice about using the main class The module's behaviour was changed from needing to include two different classes to using only the main class (class munin) directly. However, this change was not documented and it could lead to weird errors related to variables being undefined. --- README.md | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'README.md') diff --git a/README.md b/README.md index db6af95..68c3c55 100644 --- a/README.md +++ b/README.md @@ -26,6 +26,14 @@ a very easy plugin interface. The munin homepage is http://munin.projects.linpro Your modules directory will need all the files included in this repository placed under a directory called `munin`. +### Upgrade notices + +Users of the module who are upgrading from a older version of the module might be interested in these important changes: + + * The `munin::client` and `munin::host` classes should not be included + directly anymore. Instead, the main class should be used for both client and + server (server should have the `$is_server` parameter set to true). + ### Master configuration To install a master (or server) you need to flip one argument to true in the main class: -- cgit v1.2.3