My mod_wsgi django application appears to help keep getting reloaded for that first several demands the client makes. This really is killing my performance

After enough demands it appears to stay lower, and also the application no more appears to become getting reloaded. Any ideas on why this really is happening and just how I'm able to prevent it?

(I've the next in httpd.conf:MaxRequestsPerChild 0, to ensure that is not it)

This really is likely since you are utilizing embedded mode of mod_wsgi and Apache on the UNIX system, potentially with Apache prefork MPM which causes it to be all worse. In a nutshell, for the reason that configuration Apache it's a multi process web server. Mix by using proven fact that default would be to lazily load application on first request, you will notice a delay on initial request against each Apache server child process as application loads.

For Django framework this should not be excessive and would question what your particular application does on startup to result in a lengthy delay or large load spike.

To know the problems, make certain you read:

Then switch to use daemon mode of mod_wsgi rather as recorded on mod_wsgi wiki pages. Particularly begin with:

If it's truly warranted you need to run several daemon process and not simply being hopeful by what kind of load the application will get, and load time continues to be an issue, you'll be able to configure mod_wsgi using WSGIImportScript along with other techniques to preload your WSGI application at process start before any demands are available in. For Django though, make certain you utilize WSGI script file referred to in:

and never the one which Django documentation describes because it lazily loads and you will still see problem in addition to variations in behavior between WSGI hosting systems and built-in development server.