我使用django + mod-wsgi + apache开发一个网站。奇怪的是,当我启动网站时,所有其他功能都可以登录功能。当我尝试登录时,它给了我500错误。
这是错误形式error_log:
[Sat May 21 13:00:39 2011] [error] /usr/local/lib64/python2.6/site-packages/django/contrib/auth/__init__.py:26: DeprecationWarning: Authentication backends without a `supports_object_permissions` attribute are deprecated. Please define it in <class 'accounts.backends.EmailOrUsernameModelBackend.EmailOrUsernameModelBackend'>.
[Sat May 21 13:00:39 2011] [error] DeprecationWarning)
[Sat May 21 13:00:39 2011] [error] /usr/local/lib64/python2.6/site-packages/django/contrib/auth/__init__.py:31: DeprecationWarning: Authentication backends without a `supports_anonymous_user` attribute are deprecated. Please define it in <class 'accounts.backends.EmailOrUsernameModelBackend.EmailOrUsernameModelBackend'>.
[Sat May 21 13:00:39 2011] [error] DeprecationWarning)
[Sat May 21 05:00:39 2011] [notice] child pid 6693 exit signal Segmentation fault (11)
[Sat May 21 05:00:39 2011] [notice] child pid 6695 exit signal Segmentation fault (11)
请告诉我。感谢
答案 0 :(得分:2)
阅读文档以了解常见原因:
http://code.google.com/p/modwsgi/wiki/FrequentlyAskedQuestions#Apache_Process_Crashes http://code.google.com/p/modwsgi/wiki/ApplicationIssues
使用调试器尝试并追踪它:
http://code.google.com/p/modwsgi/wiki/DebuggingTechniques#Debugging_Crashes_With_GDB
很可能您的登录页面导致导入和使用的扩展模块在子解释器中不起作用。尝试使用以下命令强制该应用程序在主解释器中运行:
WSGIApplicationGroup %{GLOBAL}
有关详细信息,请参阅mod_wsgi网站上的文档。