Ori.livneh has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/125686

Change subject: Graphite/Carbon: set max open files via Upstart 'limit' 
directive
......................................................................

Graphite/Carbon: set max open files via Upstart 'limit' directive

Upstart does not respect /etc/security/limits.{conf,d}. If you want to set
limits for Upstart jobs, you have to do it explicitly in the job configuration,
via the 'limit' directive.

This patch set ulimit -n to 65k for Carbon instances and removes the limits.d
file. I'll purge the file from tungsten manually.

Change-Id: I4fa1ccf58ff700d4521a5cf19de5309b57aa9296
---
M modules/graphite/files/carbon-upstart/cache.conf
D modules/graphite/files/graphite.limits.conf
M modules/graphite/manifests/init.pp
3 files changed, 2 insertions(+), 9 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/86/125686/1

diff --git a/modules/graphite/files/carbon-upstart/cache.conf 
b/modules/graphite/files/carbon-upstart/cache.conf
index 43d8649..61b7130 100644
--- a/modules/graphite/files/carbon-upstart/cache.conf
+++ b/modules/graphite/files/carbon-upstart/cache.conf
@@ -9,6 +9,8 @@
 
 stop on runlevel [!2345] or carbon.stop
 
+limit nofile 65536 65536
+
 setuid _graphite
 setgid _graphite
 
diff --git a/modules/graphite/files/graphite.limits.conf 
b/modules/graphite/files/graphite.limits.conf
deleted file mode 100644
index cf3ed62..0000000
--- a/modules/graphite/files/graphite.limits.conf
+++ /dev/null
@@ -1,5 +0,0 @@
-# Increase file descriptor limits for Graphite
-# See <http://graphite.readthedocs.org/en/latest/carbon-daemons.html>
-# This file is managed by Puppet
-_graphite    soft    nofile    65536
-_graphite    hard    nofile    65536
diff --git a/modules/graphite/manifests/init.pp 
b/modules/graphite/manifests/init.pp
index 851c74f..8523734 100644
--- a/modules/graphite/manifests/init.pp
+++ b/modules/graphite/manifests/init.pp
@@ -33,10 +33,6 @@
         relay => $carbon_service_defaults,
     }
 
-    file { '/etc/security/limits.d/graphite.conf':
-        source => 'puppet:///modules/graphite/graphite.limits.conf',
-    }
-
     file { $storage_dir:
         ensure  => directory,
         owner   => '_graphite',

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I4fa1ccf58ff700d4521a5cf19de5309b57aa9296
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Ori.livneh <[email protected]>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to