
tfheen at varnish-cache
Jul 31, 2013, 4:02 AM
Post #1 of 1
(23 views)
Permalink
|
|
[master] bca2da5 Adjust ulimit on RPM platforms
|
|
commit bca2da56c94c0b472b667f0d1bcf2444d4ae6ff8 Author: Ingvar Hagelund <ingvar [at] redpill-linpro> Date: Wed Jul 31 13:02:18 2013 +0200 Adjust ulimit on RPM platforms The default number of processes/threads (ulimit -u) on rhel6 and clones is 1024, which is too little for varnish. This patch adds a variable NPROC to sysconfig/initscript suppport in the rpm package. If no value is set in sysconfig, it will be set to 10000. diff --git a/redhat/varnish.initrc b/redhat/varnish.initrc index c2faa25..323024b 100755 --- a/redhat/varnish.initrc +++ b/redhat/varnish.initrc @@ -53,6 +53,9 @@ start() { # Open files (usually 1024, which is way too small for varnish) ulimit -n ${NFILES:-131072} + # Open processes/threads (usually 1024 on rhel6, which is too little for varnish) + ulimit -u ${NPROC:-10000} + # Varnish wants to lock shared memory log in memory. ulimit -l ${MEMLOCK:-82000} diff --git a/redhat/varnish.sysconfig b/redhat/varnish.sysconfig index f5846c9..b1b640c 100644 --- a/redhat/varnish.sysconfig +++ b/redhat/varnish.sysconfig @@ -7,6 +7,9 @@ # Maximum number of open files (for ulimit -n) NFILES=131072 +# Maximum number of processes/threads (for ulimit -u) +NPROC=10000 + # Locked shared memory (for ulimit -l) # Default log size is 82MB + header MEMLOCK=82000 _______________________________________________ varnish-commit mailing list varnish-commit [at] varnish-cache https://www.varnish-cache.org/lists/mailman/listinfo/varnish-commit
|