Python-MySQLdb问题:ELF类错误:ELFCLASS32 [英] Python-MySQLdb problem: wrong ELF class: ELFCLASS32

查看:305
本文介绍了Python-MySQLdb问题:ELF类错误:ELFCLASS32的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

作为尝试django CMS的一部分( http://www.django-cms.org/),我正在努力使Python-MySQLdb工作( http:// pypi我已经安装了Django CMS及其所有的依赖项(其中包括:python.org / pypi / MySQL-python /

As part of trying out django CMS (http://www.django-cms.org/), I'm struggling with getting Python-MySQLdb to work (http://pypi.python.org/pypi/MySQL-python/).


    < Python 2.5,Django,django-south,MySQL服务器)
  • 我正在尝试使用MySQL作为选择的数据库类型的Django CMS代码中的示例代码

当我执行 python manage.py syncdb 时,会出现以下错误:

When I execute python manage.py syncdb, the following error occurs:


django.core.exceptions.ImproperlyConfigured:
加载MySQLdb模块时出错:
/root/.python-eggs/MySQL_python-1.2.3c1-py2。 5-linux-i686.egg-tmp / _mysql.so:
错ELF类:ELFCLASS32

django.core.exceptions.ImproperlyConfigured: Error loading MySQLdb module: /root/.python-eggs/MySQL_python-1.2.3c1-py2.5-linux-i686.egg-tmp/_mysql.so: wrong ELF class: ELFCLASS32

我已经能够跟踪问题具体到python- mySQLdb(也可以在堆栈跟踪中看到)。除此之外,我完全迷惑不解。我不知道ELFCLASS32是什么意思,还是什么ELF类。

I have been able to trace the problem specifically to python-mySQLdb (as also visible in the stack trace). Other than that, I am completely puzzled. I don't have a clue what ELFCLASS32 means, or what ELF class is anyway.

我怀疑这个错误可能与我正在运行的事实有关64位版本的Debian 5(在VPS上)。

I suspect that this error could have something to do with the fact that I am running 64-bit version of Debian 5 (on a VPS).

任何好主意如何解决问题?

Any good ideas how to troubleshoot?

推荐答案

是的,有区别的是导致这个的。查找或构建64位版本的MySQLdb。

Yes, the bit difference is what's causing this. Find or build a 64-bit version of MySQLdb.

ELF 可执行和可链接格式 ELFCLASS32 表示它是一个32位ELF文件。

ELF is the Executable and Linkable Format. ELFCLASS32 means that it's a 32-bit ELF file.

这篇关于Python-MySQLdb问题:ELF类错误:ELFCLASS32的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆