python - apache python 错误

标签 python django apache mod-wsgi wsgi

我在错误日志文件中得到了这个信息。我一直在寻找解决方案,但一无所获。我正在尝试使用 mod_wsgi 部署 django。

[Wed Jun 13 12:15:53 2012] [error] [client 207.46.13.117] ImportError: /usr/lib/python2.6/lib-dynload/_functools.so: wrong ELF class: ELFCLASS32
[Wed Jun 13 12:15:53 2012] [error] [client 207.46.13.117] mod_wsgi (pid=20219): Target WSGI script '/home/dbs/public_html/test.wsgi' cannot be loaded as Python module.
[Wed Jun 13 12:15:53 2012] [error] [client 207.46.13.117] mod_wsgi (pid=20219): Exception occurred processing WSGI script '/home/dbs/public_html/test.wsgi'.
[Wed Jun 13 12:15:53 2012] [error] [client 207.46.13.117] Traceback (most recent call last):
[Wed Jun 13 12:15:53 2012] [error] [client 207.46.13.117]   File "/home/dbs/public_html/test.wsgi", line 6, in <module>
[Wed Jun 13 12:15:53 2012] [error] [client 207.46.13.117]     import django.core.handlers.wsgi
[Wed Jun 13 12:15:53 2012] [error] [client 207.46.13.117]   File "/home/dbs/sites/domain.com/django/core/handlers/wsgi.py", line 2, in <module>
[Wed Jun 13 12:15:53 2012] [error] [client 207.46.13.117]     from threading import Lock
[Wed Jun 13 12:15:53 2012] [error] [client 207.46.13.117]   File "/usr/lib/python2.6/threading.py", line 13, in <module>
[Wed Jun 13 12:15:53 2012] [error] [client 207.46.13.117]     from functools import wraps
[Wed Jun 13 12:15:53 2012] [error] [client 207.46.13.117]   File "/usr/lib/python2.6/functools.py", line 10, in <module>
[Wed Jun 13 12:15:53 2012] [error] [client 207.46.13.117]     from _functools import partial, reduce

最佳答案

您安装的功能模块版本错误。安装正确的二进制版本,或使用纯 python 版本。

关于python - apache python 错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/11019229/

相关文章:

Python 字典 "copy value"

java - 如何将 Apache 引向 Vaadin (Java) 项目?

java - 如何在 JavaPNS 推送通知中向有效负载添加 JSON?

django - 从头开始重写 Django 应用程序,是否可以迁移用户模型?

python - Django 操作的默认参数

python - 基于 Forloop 模式的图像大小

linux - 将整个站点从 HTTP 迁移到 HTTPS 对 API 用户有何影响?

python - 计算 Pandas 数据框列中的元素

python - 尝试定位 404 Error running python-flask with bootstrap

python - 注册和登录 api 中的 Django Rest 框架