Commit ebb66701 authored by Dag Haavi Finstad's avatar Dag Haavi Finstad

Set ulimit -u (RLIMIT_NPROC) to unlimited for RHEL init script.

parent 6a9302c9
......@@ -56,6 +56,10 @@ start() {
# Varnish wants to lock shared memory log in memory.
ulimit -l ${MEMLOCK:-82000}
# Maximum number of threads (default in CentOS is 1024, which
# is often too small for varnish)
ulimit -u ${NPROCS:-unlimited}
# $DAEMON_OPTS is set in /etc/sysconfig/varnish. At least, one
# has to set up a backend, or /tmp will be used, which is a bad idea.
if [ "$DAEMON_OPTS" = "" ]; then
......
......@@ -11,6 +11,9 @@ NFILES=131072
# Default log size is 82MB + header
MEMLOCK=82000
# Maximum number of threads (for ulimit -u)
NPROCS="unlimited"
# Maximum size of corefile (for ulimit -c). Default in Fedora is 0
# DAEMON_COREFILE_LIMIT="unlimited"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment