Python论坛  - 讨论区

标题:[python-chinese] Django,MYSQL 数据库初始化失败,请教

2006年03月06日 星期一 22:36

张骏 zhangj at foreseen-info.com
Mon Mar 6 22:36:46 HKT 2006

在 2006-3-6 9:52:46,"大郎" <iexper at gmail.com> 写道:
> 这不是解决之道吧?
> 看来要快速学习LIMODOU的看来只能装sqlite3?

第一,为什么要用mysql
第二,学习django不必固定在mysql
第三,postgresql不比mysql差,甚至更好
第四,你现在遇到的问题不是django的问题,是数据库的问题。

因此我建议你用postgresql:)

对了,还有一种可能:你的mysql的python模块有问题,比如是使用低版本mysql编译出的。

-- 
张骏 <zhangj at foreseen-info.com>

敏捷来自Python
简单源于我们
丰元信信息技术有限公司



[导入自Mailman归档:http://www.zeuux.org/pipermail/zeuux-python]

2006年03月06日 星期一 23:56

马踏飞燕 honeyday.mj at gmail.com
Mon Mar 6 23:56:40 HKT 2006

在 06-3-6,大郎<iexper at gmail.com> 写道:
> 嗯。谢谢老马,呵~~
> 看到了,mysql-front已在使用中。搞了个破解的。:-)
>
> 我在my.ini文件中设置:
> default-storage-engine=mylSAM
>
> 然后再执行manage.py init
>
> 仍旧报
>
> Error: The database couldn't be initialized.
> (1289, "The 'InnoDB' feature is disabled; you need MySQL built with 'InnoDB'
> to
> have it working")
>
> 我再找找设置方面的问题。
>

看来不是你的mysql设置的问题了,可能是mysql本身的问题。
用客户端连上mysql server,输入
SHOW VARIABLES;
看看结果里面的信息。有一行是have_innodb,我的值是YES,看看你的是不是?
如果不是的话,就可能你的mysql在编译的时候没有打开这个选项,也可能你用windows安装包的时候,在安装完成配置向导的地方,没有打开innodb的特性。

忘了一件事,你是在什么操作系统上安装的mysql?是采用2进制分发安装的还是源代码编译的?这些都要说明的。

要是windows平台的话,就很好办。下载一个4.1.18,exe的文件,安装就好了。装好之后有一个配置的向导。再次运行向导可以执行bin\MySQLInstanceConfig.exe这个文件。

linux平台更简单,找一个bin分发的,直接解压到一个目录,只要保证目录的相应权限就可以了。src编译也很简单,基本就是3部曲:./configure
, make ,make install。
想玩点花样,就在configure的时候加上一些参数就OK了。

到此,理论上这个问题应该被搞定了,good luck!

[导入自Mailman归档:http://www.zeuux.org/pipermail/zeuux-python]

2006年03月07日 星期二 00:17

mikespook mikespook at gmail.com
Tue Mar 7 00:17:22 HKT 2006

在my.cnf或my.ini中加入

skip-locking
skip-innodb

试试吧~~


在06-3-6,马踏飞燕 <honeyday.mj at gmail.com> 写道:
>
> 在 06-3-6,大郎<iexper at gmail.com> 写道:
> > 嗯。谢谢老马,呵~~
> > 看到了,mysql-front已在使用中。搞了个破解的。:-)
> >
> > 我在my.ini文件中设置:
> > default-storage-engine=mylSAM
> >
> > 然后再执行manage.py init
> >
> > 仍旧报
> >
> > Error: The database couldn't be initialized.
> > (1289, "The 'InnoDB' feature is disabled; you need MySQL built with
> 'InnoDB'
> > to
> > have it working")
> >
> > 我再找找设置方面的问题。
> >
>
> 看来不是你的mysql设置的问题了,可能是mysql本身的问题。
> 用客户端连上mysql server,输入
> SHOW VARIABLES;
> 看看结果里面的信息。有一行是have_innodb,我的值是YES,看看你的是不是?
>
> 如果不是的话,就可能你的mysql在编译的时候没有打开这个选项,也可能你用windows安装包的时候,在安装完成配置向导的地方,没有打开innodb的特性。
>
> 忘了一件事,你是在什么操作系统上安装的mysql?是采用2进制分发安装的还是源代码编译的?这些都要说明的。
>
> 要是windows平台的话,就很好办。下载一个4.1.18,exe
> 的文件,安装就好了。装好之后有一个配置的向导。再次运行向导可以执行bin\MySQLInstanceConfig.exe这个文件。
>
>
> linux平台更简单,找一个bin分发的,直接解压到一个目录,只要保证目录的相应权限就可以了。src编译也很简单,基本就是3部曲:./configure
> , make ,make install。
> 想玩点花样,就在configure的时候加上一些参数就OK了。
>
> 到此,理论上这个问题应该被搞定了,good luck!
>
> _______________________________________________
> python-chinese
> Post: send python-chinese at lists.python.cn
> Subscribe: send subscribe to python-chinese-request at lists.python.cn
> Unsubscribe: send unsubscribe to  python-chinese-request at lists.python.cn
> Detail Info: http://python.cn/mailman/listinfo/python-chinese
>
>


--
mikespook & swill

http://www.xxiyy.com
http://main.xxiyy.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.exoweb.net/pipermail/python-chinese/attachments/20060307/173a8133/attachment.htm

[导入自Mailman归档:http://www.zeuux.org/pipermail/zeuux-python]

2006年03月07日 星期二 00:58

Bo Yang boyang at mac.com
Tue Mar 7 00:58:17 HKT 2006

mysql可以用户自己选择数据库引擎。最常用的是MyISAM和InnoDB.  MyISAM低并 
发的时候快一些,但是InnoDB支持transaction事务处理。

看起来是你用的mysql执行程序没有把InnoDB选项编译进去。换一个完整的mysql 
安装就可以了。

- 阿北

On Mar 5, 2006, at 1:06 PM, 大郎 wrote:

> 这里不能使用引号地?
> 我试着去掉后,测试时信息如下:
>
> D:\python\newtest>manage.py init
> Error: The database couldn't be initialized.
> (1289, "The 'InnoDB' feature is disabled; you need MySQL built with  
> 'InnoDB' to
> have it working")
>
> 'InnoDB',这是什么东东?3Q
> _______________________________________________
> python-chinese
> Post: send python-chinese at lists.python.cn
> Subscribe: send subscribe to python-chinese-request at lists.python.cn
> Unsubscribe: send unsubscribe to  python-chinese- 
> request at lists.python.cn
> Detail Info: http://python.cn/mailman/listinfo/python-chinese


[导入自Mailman归档:http://www.zeuux.org/pipermail/zeuux-python]

2006年03月07日 星期二 13:42

风向标 vaneoooo at gmail.com
Tue Mar 7 13:42:28 HKT 2006

...
阿北都浮出水面参加讨论了
今儿什么日子?


在06-3-7,Bo Yang <boyang at mac.com> 写道:
>
> mysql可以用户自己选择数据库引擎。最常用的是MyISAM和InnoDB.  MyISAM低并
> 发的时候快一些,但是InnoDB支持transaction事务处理。
>
> 看起来是你用的mysql执行程序没有把InnoDB选项编译进去。换一个完整的mysql
> 安装就可以了。
>
> - 阿北
>
> On Mar 5, 2006, at 1:06 PM, 大郎 wrote:
>
> > 这里不能使用引号地?
> > 我试着去掉后,测试时信息如下:
> >
> > D:\python\newtest>manage.py init
> > Error: The database couldn't be initialized.
> > (1289, "The 'InnoDB' feature is disabled; you need MySQL built with
> > 'InnoDB' to
> > have it working")
> >
> > 'InnoDB',这是什么东东?3Q
> > _______________________________________________
> > python-chinese
> > Post: send python-chinese at lists.python.cn
> > Subscribe: send subscribe to python-chinese-request at lists.python.cn
> > Unsubscribe: send unsubscribe to  python-chinese-
> > request at lists.python.cn
> > Detail Info: http://python.cn/mailman/listinfo/python-chinese
>
> _______________________________________________
> python-chinese
> Post: send python-chinese at lists.python.cn
> Subscribe: send subscribe to python-chinese-request at lists.python.cn
> Unsubscribe: send unsubscribe to  python-chinese-request at lists.python.cn
> Detail Info: http://python.cn/mailman/listinfo/python-chinese
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.exoweb.net/pipermail/python-chinese/attachments/20060307/df27d610/attachment.html

[导入自Mailman归档:http://www.zeuux.org/pipermail/zeuux-python]

2006年03月07日 星期二 14:49

Zoom Quiet zoom.quiet at gmail.com
Tue Mar 7 14:49:05 HKT 2006

On 3/7/06, 风向标 <vaneoooo at gmail.com> wrote:
>
> ...
> 阿北都浮出水面参加讨论了
> 今儿什么日子?

豆瓣网,出生一年零一天!

>
> 在06-3-7,Bo Yang <boyang at mac.com> 写道:
> > mysql可以用户自己选择数据库引擎。最常用的是MyISAM和InnoDB.  MyISAM低并
> > 发的时候快一些,但是InnoDB支持transaction事务处理。
> >
> > 看起来是你用的mysql执行程序没有把InnoDB选项编译进去。换一个完整的mysql
> > 安装就可以了。
> >
> > - 阿北
> >
> > On Mar 5, 2006, at 1:06 PM, 大郎 wrote:
> >
> > > 这里不能使用引号地?
> > > 我试着去掉后,测试时信息如下:
> > >
> > > D:\python\newtest>manage.py init
> > > Error: The database couldn't be initialized.
> > > (1289, "The 'InnoDB' feature is disabled; you need MySQL built with
> > > 'InnoDB' to
> > > have it working")
> > >
> > > 'InnoDB',这是什么东东?3Q
> > > _______________________________________________
> > > python-chinese
> > > Post: send python-chinese at lists.python.cn
> > > Subscribe: send subscribe to
> python-chinese-request at lists.python.cn
> > > Unsubscribe: send unsubscribe to  python-chinese-
> > > request at lists.python.cn
> > > Detail Info:
> http://python.cn/mailman/listinfo/python-chinese
> >
> > _______________________________________________
> > python-chinese
> > Post: send python-chinese at lists.python.cn
> > Subscribe: send subscribe to
> python-chinese-request at lists.python.cn
> > Unsubscribe: send unsubscribe to
> python-chinese-request at lists.python.cn
> > Detail Info:
> http://python.cn/mailman/listinfo/python-chinese
> >
>
>
> _______________________________________________
> python-chinese
> Post: send python-chinese at lists.python.cn
> Subscribe: send subscribe to
> python-chinese-request at lists.python.cn
> Unsubscribe: send unsubscribe to
> python-chinese-request at lists.python.cn
> Detail Info:
> http://python.cn/mailman/listinfo/python-chinese
>
>


--
"""Time is unimportant, only life important!
blogging  :  http://blog.zoomquiet.org/pyblosxom/
wiki enter:   http://wiki.woodpecker.org.cn/moin/ZoomQuiet
in douban:  http://www.douban.com/people/zoomq/
"""

[导入自Mailman归档:http://www.zeuux.org/pipermail/zeuux-python]

如下红色区域有误,请重新填写。

    你的回复:

    请 登录 后回复。还没有在Zeuux哲思注册吗?现在 注册 !

    Zeuux © 2025

    京ICP备05028076号