title: apache/mod_wsgi: How do I spawn specific number of processes?
body: <p>How do I spawn a specific number of processes in Apache when using mod_wsgi with the WSGIDaemonProcess setting?</p>
  
  <p>I have my VirtualHost setup with the following (as a test):</p>
  
  <pre><code>WSGIDaemonProcess webserver user=webserver group=webserver processes=24 threads=8 display-name=%{GROUP} python-path=/var/virtualenv/lib/python2.6/site-packages
  </code></pre>
  
  <p>While my httpd.conf is setup as follows:</p>
  
  <pre><code>&lt;IfModule prefork.c&gt;
  StartServers       8
  MinSpareServers    1
  MaxSpareServers    8
  ServerLimit       24
  MaxClients        24
  MaxRequestsPerChild  4000
  &lt;/IfModule&gt;
  </code></pre>
  
  <p>Note, that I'm running a very constrained 256MB server with PostgreSQL database installed as well.</p>
  
  <p>However, system shows far more than 24 processes for apache (more than 30). I expected that if I set the ServerLimit to the same as processes in WSGIDaemonProcess it would run at the constant 24. However, there seems to be a bunch of spare processes running for unknown reasons?</p>