Gehel has submitted this change and it was merged.

Change subject: elasticsearch - check shards via the service, not via each 
individual node
......................................................................


elasticsearch - check shards via the service, not via each individual node

Checking cluster state on each node is redundant and generate a lot of noise.
Cluster wide checks are now done on the service only.

The logstash cluster is left unchanged as it does not have LVS.

The relforge cluster is at the moment left unmonitored. This will be
fixed once a cleanup of the different elasticsearch roles is done (see
https://gerrit.wikimedia.org/r/#/c/304067/).

Bug: T133844
Change-Id: Ica721152c10d777003726e80fa03ed82c69c8a10
---
M manifests/role/icinga.pp
M modules/elasticsearch/manifests/nagios/check.pp
A modules/icinga/manifests/monitor/elasticsearch.pp
M modules/role/manifests/elasticsearch/server.pp
4 files changed, 22 insertions(+), 2 deletions(-)

Approvals:
  Gehel: Looks good to me, approved
  EBernhardson: Looks good to me, but someone else must approve
  jenkins-bot: Verified

Objections:
  Faidon Liambotis: There's a problem with this change, please improve



diff --git a/manifests/role/icinga.pp b/manifests/role/icinga.pp
index 3e7977c..c40bf8a 100644
--- a/manifests/role/icinga.pp
+++ b/manifests/role/icinga.pp
@@ -24,6 +24,7 @@
     include icinga::monitor::certs
     include icinga::monitor::gsb
     include icinga::monitor::commons
+    include icinga::monitor::elasticsearch
     include lvs::monitor
     include role::authdns::monitoring
     include netops::monitoring
diff --git a/modules/elasticsearch/manifests/nagios/check.pp 
b/modules/elasticsearch/manifests/nagios/check.pp
index bc19b24..ce651c7 100644
--- a/modules/elasticsearch/manifests/nagios/check.pp
+++ b/modules/elasticsearch/manifests/nagios/check.pp
@@ -1,4 +1,4 @@
-# == Class elasticsearch::notifications
+# == Class elasticsearch::nagios::check
 # Sets up icinga alerts for an elasticsearch instance.
 # Make sure your Nagios/Icinga node has included
 # the elasticsearch::nagios::plugin class.
diff --git a/modules/icinga/manifests/monitor/elasticsearch.pp 
b/modules/icinga/manifests/monitor/elasticsearch.pp
new file mode 100644
index 0000000..164b180
--- /dev/null
+++ b/modules/icinga/manifests/monitor/elasticsearch.pp
@@ -0,0 +1,20 @@
+# monitor the different elasticsearch clusters
+class icinga::monitor::elasticsearch {
+
+    monitoring::service { 'elasticsearch shards - eqiad':
+        host          => 'search.svc.eqiad.wmnet',
+        check_command => 'check_elasticsearch_shards',
+        description   => 'ElasticSearch health check for shards',
+        critical      => true,
+        contact_group => 'admins,team-discovery',
+    }
+
+    monitoring::service { 'elasticsearch shards - codfw':
+        host          => 'search.svc.codfw.wmnet',
+        check_command => 'check_elasticsearch_shards',
+        description   => 'ElasticSearch health check for shards',
+        critical      => true,
+        contact_group => 'admins,team-discovery',
+    }
+
+}
diff --git a/modules/role/manifests/elasticsearch/server.pp 
b/modules/role/manifests/elasticsearch/server.pp
index ac7db8c..fff8196 100644
--- a/modules/role/manifests/elasticsearch/server.pp
+++ b/modules/role/manifests/elasticsearch/server.pp
@@ -64,7 +64,6 @@
     include ::elasticsearch::https
     include elasticsearch::monitor::diamond
     include ::elasticsearch::log::hot_threads
-    include ::elasticsearch::nagios::check
 
     file { '/etc/elasticsearch/scripts':
         ensure  => absent,

-- 
To view, visit https://gerrit.wikimedia.org/r/305519
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ica721152c10d777003726e80fa03ed82c69c8a10
Gerrit-PatchSet: 3
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Gehel <gleder...@wikimedia.org>
Gerrit-Reviewer: DCausse <dcau...@wikimedia.org>
Gerrit-Reviewer: EBernhardson <ebernhard...@wikimedia.org>
Gerrit-Reviewer: Faidon Liambotis <fai...@wikimedia.org>
Gerrit-Reviewer: Gehel <gleder...@wikimedia.org>
Gerrit-Reviewer: jenkins-bot <>

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to