J'essaye d'exécuter mes sites Django avec mod_wsgi au lieu de mod_python (RHEL 5). J'ai essayé ceci avec tous mes emplacements, mais obtiens le même problème. Je l'ai configuré de la manière standard que tout le monde recommande, mais demande simplement au site d'expirer.Exécution d'un site Django sous mod_wsgi
Apache conf:
<VirtualHost 74.54.144.34>
DocumentRoot /wwwclients/thymeandagain
ServerName thymeandagain4corners.com
ServerAlias www.thymeandagain4corners.com
LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined
CustomLog /var/log/httpd/thymeandagain_access_log combined
ErrorLog /var/log/httpd/thymeandagain_error_log
LogLevel error
WSGIScriptAlias//wwwclients/thymeandagain/wsgi_handler.py
WSGIDaemonProcess thymeandagain user=admin group=admin processes=1 threads=16
WSGIProcessGroup thymeandagain
</VirtualHost>
wsgi_handler.py:
import sys
import os
sys.path.append("/wwwclients")
os.environ['DJANGO_SETTINGS_MODULE'] = 'thymeandagain.settings'
import django.core.handlers.wsgi
application = django.core.handlers.wsgi.WSGIHandler()
Le démon mod_wsgi est censé se reproduire au large est pas là, en fait la demande juste le temps et je reçois un tas de « Impossible pour se connecter au processus démon WSGI "dans les journaux. La directive WSGIDaemonProcess empêche-t-elle la création du démon? Merci d'avance pour toute aide ...
EDIT: Je reçois cela dans le journal des erreurs:
[[email protected]] mcm_server_readable():2582: timeout: Operation now in progress: select(2) call timed out for read(2)able fds
[[email protected]] mcm_get_line():1592
[[email protected]] mcm_server_readable():2582: timeout: Operation now in progress: select(2) call timed out for read(2)able fds
[[email protected]] mcm_get_line():1592
[Thu Nov 20 21:18:17 2008] [notice] caught SIGTERM, shutting down
[Thu Nov 20 21:18:18 2008] [notice] Digest: generating secret for digest authentication ...
[Thu Nov 20 21:18:18 2008] [notice] Digest: done
[Thu Nov 20 21:18:18 2008] [notice] mod_python: Creating 4 session mutexes based on 8 max processes and 64 max threads.
[Thu Nov 20 21:18:18 2008] [notice] Apache/2.2.3 (Red Hat) mod_python/3.2.8 Python/2.4.3 mod_wsgi/2.1-BRANCH configured -- resuming normal operations
Y at-il quelque chose dans le journal des erreurs du serveur? Je pense que cela vous dirait s'il y avait un problème lors du démarrage du démon WSGI. – Powerlord
Cela a résolu mon problème http://blog.dscpl.com.au/2010/03/improved-wsgi-script-for-use-with.html –