summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMicah Anderson <micah@riseup.net>2010-10-17 18:08:42 -0400
committerMicah Anderson <micah@riseup.net>2010-10-17 18:08:42 -0400
commit0ab822f209fd5b4e703f7608b375ba5780fa5364 (patch)
treecc7e515161e8f0b9f03d55136d1a1bba7af79ea4
parent4e35b0bce0f2dd00d52e0de7488ab322867dd012 (diff)
Revert "add a nagios::service::mysql_health define to facilitate the creation of the check_mysql_health mysql nagios plugin. See the mysql module for the installation of this plugin, and example usage"
This reverts commit 45edca107c3fd158fc9b00aa90f9f3f6d730185a. reverted because this is much easier to handle within the mysql module itself.
-rw-r--r--manifests/service/mysql.pp51
1 files changed, 0 insertions, 51 deletions
diff --git a/manifests/service/mysql.pp b/manifests/service/mysql.pp
index 2605e8d..ca2ae15 100644
--- a/manifests/service/mysql.pp
+++ b/manifests/service/mysql.pp
@@ -46,54 +46,3 @@ define nagios::service::mysql(
}
}
-
-define nagios::service::mysql_health(
- $ensure = present,
- $check_hostname = $fqdn,
- $check_port = '3306',
- $check_username = 'nagios',
- $check_password = $nagios_mysql_password,
- $check_database = 'information_schema',
- $check_warning = undef,
- $check_critical = undef,
- $check_health_mode = $name,
- $check_name = undef,
- $check_name2 = undef,
- $check_regexp = undef,
- $check_units = undef,
- $check_mode = 'tcp'
-){
-
- if ($check_username == '') {
- $real_check_username = 'nagios'
- }
-
- case $check_mode {
- 'tcp': {
- if ($check_hostname == 'localhost') {
- $real_check_hostname = '127.0.0.1'
- }
- else {
- $real_check_hostname = $check_hostname
- }
- }
- default: {
- if ($check_hostname == '127.0.0.1') {
- $real_check_hostname = 'localhost'
- }
- else {
- $real_check_hostname = $check_hostname
- }
- }
- }
-
- nagios::service { 'mysql_health_${check_health_mode}':
- ensure => $ensure,
- check_command => "check_mysql_health!${check_hostname}!${check_port}!${real_check_username}!${check_password}${check_health_mode}!{check_database}",
- }
-}
-
-
-
-
-