coren has uploaded a new change for review.
https://gerrit.wikimedia.org/r/201232
Change subject: Labs: make net saturation monitoring configurable
......................................................................
Labs: make net saturation monitoring configurable
Defaulting to eth0 but set to bond0 for labstore1001
Change-Id: I0d010f9caf88a3b8720cc380d60d953026509995
---
M hieradata/hosts/labstore1001.yaml
M manifests/role/labsnfs.pp
2 files changed, 5 insertions(+), 3 deletions(-)
git pull ssh://gerrit.wikimedia.org:29418/operations/puppet
refs/changes/32/201232/1
diff --git a/hieradata/hosts/labstore1001.yaml
b/hieradata/hosts/labstore1001.yaml
index 1b75a62..03930d6 100644
--- a/hieradata/hosts/labstore1001.yaml
+++ b/hieradata/hosts/labstore1001.yaml
@@ -1,3 +1,4 @@
base::resolving::domain_search:
- wikimedia.org
- eqiad.wmnet
+role::labs::nfs::fileserver::monitor_iface: bond0
diff --git a/manifests/role/labsnfs.pp b/manifests/role/labsnfs.pp
index 9a67d69..a4d7a15 100644
--- a/manifests/role/labsnfs.pp
+++ b/manifests/role/labsnfs.pp
@@ -37,7 +37,7 @@
# The role class for the NFS servers that provide general filesystem
# services to Labs.
#
-class role::labs::nfs::fileserver {
+class role::labs::nfs::fileserver($monitor_iface = 'eth0') {
include standard
# eqiad still uses LDAP for now
@@ -53,9 +53,10 @@
include openstack::project-nfs-storage-service
include openstack::replica_management_service
+ iface =
monitoring::graphite_threshold { 'network_out_saturated':
description => 'Outgoing network saturation',
- metric => "servers.${::hostname}.network.bond0.tx_byte.value",
+ metric =>
"servers.${::hostname}.network.${monitor_iface}.tx_byte.value",
from => '30min',
warning => '75000000', # roughly 600Mbps / 1Gbps
critical => '100000000', # roughly 800Mbps / 1Gbps
@@ -64,7 +65,7 @@
monitoring::graphite_threshold { 'network_in_saturated':
description => 'Incoming network saturation',
- metric => "servers.${::hostname}.network.bond0.rx_byte.value",
+ metric =>
"servers.${::hostname}.network.${monitor_iface}.rx_byte.value",
from => '30min',
warning => '75000000', # roughly 600Mbps / 1Gbps
critical => '100000000', # roughly 800Mbps / 1Gbps
--
To view, visit https://gerrit.wikimedia.org/r/201232
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I0d010f9caf88a3b8720cc380d60d953026509995
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: coren <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits