diff --git a/manifests/server/munin/base.pp b/manifests/server/munin/base.pp index 50aa084..a5331c5 100644 --- a/manifests/server/munin/base.pp +++ b/manifests/server/munin/base.pp @@ -3,22 +3,18 @@ class mysql::server::munin::base { file { "/usr/local/share/munin-plugins/mysql_connections": source => "$fileserver/munin/mysql_connections", - mode => 0755, owner => root, group => root, - script_path_in => "/usr/local/share/munin-plugins"; + mode => 0755, owner => root, group => root; "/usr/local/share/munin-plugins/mysql_qcache": source => "$fileserver/munin/mysql_qcache", - mode => 0755, owner => root, group => root, - script_path_in => "/usr/local/share/munin-plugins"; + mode => 0755, owner => root, group => root; "/usr/local/share/munin-plugins/mysql_qcache_mem": source => "$fileserver/munin/mysql_qcache_mem", - mode => 0755, owner => root, group => root, - script_path_in => "/usr/local/share/munin-plugins"; + mode => 0755, owner => root, group => root; "/usr/local/share/munin-plugins/mysql_size_all": source => "$fileserver/munin/mysql_size_all", - mode => 0755, owner => root, group => root, - script_path_in => "/usr/local/share/munin-plugins"; + mode => 0755, owner => root, group => root; } } diff --git a/manifests/server/munin/debian.pp b/manifests/server/munin/debian.pp index d657674..b746f87 100644 --- a/manifests/server/munin/debian.pp +++ b/manifests/server/munin/debian.pp @@ -1,9 +1,14 @@ # manifests/server/munin/debian.pp class mysql::server::munin::debian inherits mysql::server::munin::base { - munin::plugin { - [mysql_bytes, mysql_queries, mysql_slowqueries, mysql_threads, mysql_connections, mysql_qcache, mysql_cache_mem, mysql_size_all]: - config => "user root\nenv.mysqlopts --defaults-file=/etc/mysql/debian.cnf", - require => Package['mysql'], - } + munin::plugin { + [ mysql_bytes, mysql_queries, mysql_slowqueries, mysql_threads ]: + config => "user root\nenv.mysqlopts --defaults-file=/etc/mysql/debian.cnf", + require => Package['mysql']; + + [ mysql_connections, mysql_qcache, mysql_cache_mem, mysql_size_all ]: + config => "user root\nenv.mysqlopts --defaults-file=/etc/mysql/debian.cnf", + script_path_in => "/usr/local/share/munin-plugins"; + require => Package['mysql']; + } } diff --git a/manifests/server/munin/default.pp b/manifests/server/munin/default.pp index bd68e42..2660ea0 100644 --- a/manifests/server/munin/default.pp +++ b/manifests/server/munin/default.pp @@ -16,8 +16,13 @@ class mysql::server::munin::default inherits mysql::server::munin::base { } munin::plugin { - [mysql_bytes, mysql_queries, mysql_slowqueries, mysql_threads, mysql_connections, mysql_qcache, mysql_cache_mem, mysql_size_all]: - config => "env.mysqlopts --user=munin --password=${munin_mysql_password} -h localhost", - require => [ Mysql_grant['munin@localhost'], Mysql_user['munin@localhost'], Package['mysql'] ] + [ mysql_bytes, mysql_queries, mysql_slowqueries, mysql_threads ]: + config => "env.mysqlopts --user=munin --password=${munin_mysql_password} -h localhost", + require => [ Mysql_grant['munin@localhost'], Mysql_user['munin@localhost'], Package['mysql'] ]; + + [ mysql_connections, mysql_qcache, mysql_cache_mem, mysql_size_all ]: + script_path_in => "/usr/local/share/munin-plugins", + config => "env.mysqlopts --user=munin --password=${munin_mysql_password} -h localhost", + require => [ Mysql_grant['munin@localhost'], Mysql_user['munin@localhost'], Package['mysql'] ]; } }