title: (2)No such file or directory: mod_wsgi (pid=24507)
body: <p>I have an a few Django apps running on Ubuntu Precise and Ubuntu Lucid.
  I've noticed that sometimes in my logs I've got a few 503's. During those 503's I've found these logs in my apache error logs:</p>
  
  <blockquote>
    <p>(2) <code>No such file or directory: mod_wsgi (pid=24507): Unable to connect to WSGI daemon process 'appname' on '/var/run/apache2/wsgi.27607.2.18.sock' after multiple attempts</code></p>
  </blockquote>
  
  <p>All of my apps have WSGIDaemon mode set with similar setting to this:</p>
  
  <pre><code>WSGIDaemonProcess appname display-name=wsgi-appname \
          processes=4 \
          threads=4 \
          maximum-requests=1000 \
          inactivity-timeout=120 \
          deadlock-timeout=60 \
          shutdown-timeout=5
  WSGIProcessGroup appname
  </code></pre>
  
  <p>The mod_wsgi docs have reference to this issue here: <a href="https://code.google.com/p/modwsgi/wiki/ConfigurationIssues#Location_Of_UNIX_Sockets" rel="nofollow">https://code.google.com/p/modwsgi/wiki/ConfigurationIssues#Location_Of_UNIX_Sockets</a>
  But that doesn't seem to apply to my situation since I only see the error occasionally. </p>
  
  <p>An interesting thing to note:
  On my one server apache was started March 12th. The last time I saw an error was <code>Mar 25 18:02:32</code>, which matches the create date of the <code>.sock</code> file.
  Edit: this timestamp updates when an apache reload happens. I wonder if the reload is causing the 503s...</p>
  
  <p>Does anyone know why this is happening or how I can debug it?</p>