Djang+apache+ mod_python 还是搞起来了!

Djang+apache+ mod_python 还是搞起来了!

apache  mod_python  都编译安装测试正常
安装Djang
在/usr/local/lib/python2.4/site-packages/Django-0.91-py2.4.egg/django/conf/project_template 下

按说明运行 python manage.py runserver
总是报告数据库错误,按说明改了global_settings.py  project_template/settings.py

[Copy to clipboard] [ - ]
CODE:
Validating models...
Unhandled exception in thread started by <function inner_run at 0xb7201534>
Traceback (most recent call last):
  File "/usr/local/lib/python2.4/site-packages/Django-0.91-py2.4.egg/django/core/management.py", line 757, in inner_run
    validate()
  File "/usr/local/lib/python2.4/site-packages/Django-0.91-py2.4.egg/django/core/management.py", line 741, in validate
    num_errors = get_validation_errors(outfile)
  File "/usr/local/lib/python2.4/site-packages/Django-0.91-py2.4.egg/django/core/management.py", line 634, in get_validation_errors
    import django.models
  File "/usr/local/lib/python2.4/site-packages/Django-0.91-py2.4.egg/django/models/__init__.py", line 1, in ?
    from django.core import meta
  File "/usr/local/lib/python2.4/site-packages/Django-0.91-py2.4.egg/django/core/meta/__init__.py", line 3, in ?
    from django.core import db
  File "/usr/local/lib/python2.4/site-packages/Django-0.91-py2.4.egg/django/core/db/__init__.py", line 23, in ?
    raise ImproperlyConfigured, "Could not load database backend: %s. Is your DATABASE_ENGINE setting (currently, %r) spelled correctly? Available options are: %s" % \
django.core.exceptions.ImproperlyConfigured: Could not load database backend: No module named MySQLdb. Is your DATABASE_ENGINE setting (currently, 'mysql') spelled correctly? Available options are: 'ado_mssql', 'mysql', 'postgresql', 'sqlite3'

看看哪个大哥给看看吧,实在是google不到了!

可能是数据库没有配对,如不是mysql, sqlite3。还有一种可能是相关的模块没有安装。django不自带这些数据库的对应的包,需要自行下载并安装。再有就是导入相关的模块出错。

一步一步查吧。
有没有一个详细一点的Djang 安装过程给介绍介绍
我想加数据库如何设置??
唉还是比较郁闷!再看看吧!
一定是模块儿没有装,我开始的时候也是这样,后来认真的看了ibm上的那篇文章,就弄好了
我看邮件列表里有人回答 mod_python  现在还不支持apache2.2.2,用2.0X试试

建议学习时先使用自带的server来测试。先不要使用apache。

数据库的配置看settings.py很清楚啊。
mod_python的官方网站上说, 目前版本的mod_python现在还不支持apache2.2.2,用2.0X试试
This release works with Apache HTTP Server 2.0. HTTP Server 2.2 is not yet supported. Also note that this version will not work with older releases of Apache HTTP Server.

mod_python: 3.2.8