Alexandros Kosiaris has uploaded a new change for review. (
https://gerrit.wikimedia.org/r/364708 )
Change subject: WIP: Monitoring: Simplify BMC hostnames
......................................................................
WIP: Monitoring: Simplify BMC hostnames
Drop the $::site.wmnet suffix from all hostnames, making the defined BMC
hostnames more aligned to the current status quo of only using hostnames
and not FQDN. Amend check_fqdn respectively to now check to FQDN against
the IP
Change-Id: Ie77daf21c8c9d8716ffc15d316ec936de9572bbe
---
M modules/monitoring/manifests/host.pp
M modules/nagios_common/files/checkcommands.cfg
2 files changed, 10 insertions(+), 10 deletions(-)
git pull ssh://gerrit.wikimedia.org:29418/operations/puppet
refs/changes/08/364708/1
diff --git a/modules/monitoring/manifests/host.pp
b/modules/monitoring/manifests/host.pp
index 2f76db3..9e99a6d 100644
--- a/modules/monitoring/manifests/host.pp
+++ b/modules/monitoring/manifests/host.pp
@@ -66,9 +66,9 @@
# We have a BMC, and the BMC is configured and it has an IP address
if $facts['has_ipmi'] and $facts['ipmi_lan'] and 'ipaddress' in
$facts['ipmi_lan'] {
$mgmt_host = {
- "${title}.mgmt.${::site}.wmnet" => {
+ "${title}.mgmt" => {
ensure => $ensure,
- host_name => "${title}.mgmt.${::site}.wmnet",
+ host_name => "${title}.mgmt",
address => $facts['ipmi_lan']['ipaddress'],
hostgroups => 'mgmt',
check_command => 'check_ping!500,20%!2000,100%',
@@ -119,17 +119,17 @@
create_resources($rtype, $host)
if $mgmt_host {
create_resources($rtype, $mgmt_host)
- monitoring::service { "dns_${title}.mgmt.${::site}.wmnet":
- description => "DNS ${title}.mgmt.${::site}.wmnet",
- host => "${title}.mgmt.${::site}.wmnet",
- check_command => 'check_fqdn',
+ monitoring::service { "dns_${title}.mgmt":
+ description => "DNS ${title}.mgmt",
+ host => "${title}.mgmt",
+ check_command => "check_fqdn!${title}.mgmt.${::site}.wmnet",
group => 'mgmt',
check_interval => 60,
retry_interval => 60,
}
- monitoring::service { "ssh_${title}.mgmt.${::site}.wmnet":
- description => "SSH ${title}.mgmt.${::site}.wmnet",
- host => "${title}.mgmt.${::site}.wmnet",
+ monitoring::service { "ssh_${title}.mgmt":
+ description => "SSH ${title}.mgmt",
+ host => "${title}.mgmt",
check_command => 'check_ssh',
group => 'mgmt',
check_interval => 60,
diff --git a/modules/nagios_common/files/checkcommands.cfg
b/modules/nagios_common/files/checkcommands.cfg
index a01fb98..8c4f9d1 100644
--- a/modules/nagios_common/files/checkcommands.cfg
+++ b/modules/nagios_common/files/checkcommands.cfg
@@ -62,7 +62,7 @@
define command {
command_name check_fqdn
- command_line $USER1$/check_dns -H $HOSTNAME$ -a $HOSTADDRESS$
+ command_line $USER1$/check_dns -H $ARG1$ -a $HOSTADDRESS$
}
# 'check_ftp' command definition
--
To view, visit https://gerrit.wikimedia.org/r/364708
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: Ie77daf21c8c9d8716ffc15d316ec936de9572bbe
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Alexandros Kosiaris <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits