title: Django, uWSGI & nginx: Process dies for "no reason"
body: <p>I am using uWSGI and nginx to run two parallell Django apps. One of them, the one with somewhat more load (both are very small) keeps dying about once every 24 hours with the following message:</p>
  
  <p><code>[pid: 16358|app: 0|req: 1000/1000] 127.0.0.1 () {46 vars in 847 bytes} [Thu Mar 24 16:38:31 2011] GET /aktivitet/409/picknick/ => generated 18404 bytes in 117 msecs (HTTP/1.0 200) 3 headers in 156 bytes (1 switches on core 0)
  <strong>...The work of process 16358 is done. Seeya!</strong></code></p>
  
  <p>I am launching the processess using Supervisor with the following config:</p>
  
  <p><code>[program:uttrakad]
  command=/home/myuser/webapps/uwsgi_test/bin/uwsgi
    -s /home/myuser/webapps/uwsgi_test/app1.sock
    -C /home/myuser/webapps/django/app1.wsgi
    --processes 1
    --harakiri 120
    --max-requests 1000
  autostart=true
  autorestart=true
  stdout_logfile=/home/myuser/logs/user/uwsgi_app1.log
  redirect_stderr=true
  stopsignal=QUIT</code></p>
  
  <p>The .wsgi file is simple:</p>
  
  <p><code>
  import os
  import sys
  sys.path =['/home/openworks/webapps/django/lib/python2.6/','/home/openworks/webapps/django/','/home/openworks/webapps/django/app1/'] + sys.path
  from django.core.handlers.wsgi import WSGIHandler
  os.environ['DJANGO_SETTINGS_MODULE'] = 'app1.prod_settings'
  application = WSGIHandler()
  </code></p>
  
  <p>nginx is set up with 2 worker processes, 2048 worker_connections and like this:
  <code>
  location / {
                  uwsgi_pass     unix:///home/openworks/webapps/uwsgi_test/app1.sock;
                  include        uwsgi_params;
          }
  </code></p>
  
  <p>As I said, there is one more app configured the exact same way that has been running without interuption, but is almost has no traffic. </p>
  
  <p>Any clues? Why do I get the "<em>...The work of process 16358 is done. Seeya</em>" messsage?</p>
  
  <p>Thanks</p>