mysql – 南迁移错误,InnoDB:ROW_FORMAT = DYNAMIC需要innodb_file_format>羚羊
内容导读
互联网集市收集整理的这篇技术教程文章主要介绍了mysql – 南迁移错误,InnoDB:ROW_FORMAT = DYNAMIC需要innodb_file_format>羚羊,小编现在分享给大家,供广大互联网技能从业者学习和参考。文章包含4855字,纯文字阅读大概需要7分钟。
内容图文
![mysql – 南迁移错误,InnoDB:ROW_FORMAT = DYNAMIC需要innodb_file_format>羚羊](/upload/InfoBanner/zyjiaocheng/911/9c5be8da961943d684062f6eededfdab.jpg)
我迁移数据发生错误.
我试着在下面运行原始sql:
ALTER TABLE wxwall_participation ADD COLUMN事件INT DEFAULT 0
ALTER TABLE wxwall_scene ADD COLUMN welcome_msg VARCHAR(400)NULL
它们工作得非常好,这让我很开心.我怎么能解决这个问题呢?
错误细节:
- Migrating forwards to 0002_auto__add_field_participation_event__add_field_scene_welcome_msg.
> wxwall:0002_auto__add_field_participation_event__add_field_scene_welcome_msg
! Error found during real run of migration! Aborting.
! Since you have a database that does not support running
! schema-altering statements in transactions, we have had
! to leave it in an interim state between migrations.
! You *might* be able to recover with: - no dry run output for delete_foreign_key() due to dynamic DDL, sorry
= ALTER TABLE `wxwall_participation` DROP COLUMN `event` CASCADE; []
- no dry run output for delete_foreign_key() due to dynamic DDL, sorry
= ALTER TABLE `wxwall_scene` DROP COLUMN `welcome_msg` CASCADE; []
! The South developers regret this has happened, and would
! like to gently persuade you to consider a slightly
! easier-to-deal-with DBMS (one that supports DDL transactions)
! NOTE: The error which caused the migration to fail is further up.
Error in migration: wxwall:0002_auto__add_field_participation_event__add_field_scene_welcome_msg
File "E:\PyCharm 3.0.1\helpers\pydev\pydevd.py", line 1534, in <module>
debugger.run(setup['file'], None, None)
File "E:\PyCharm 3.0.1\helpers\pydev\pydevd.py", line 1145, in run
pydev_imports.execfile(file, globals, locals) #execute the script
File "D:/YUNTU/Incubations/Project/chlitina/germes/manage.py", line 36, in <module>
execute_from_command_line(sys.argv)
File "E:\Python27\lib\site-packages\django\core\management\__init__.py", line 443, in execute_from_command_line
utility.execute()
File "E:\Python27\lib\site-packages\django\core\management\__init__.py", line 382, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File "E:\Python27\lib\site-packages\django\core\management\base.py", line 196, in run_from_argv
self.execute(*args, **options.__dict__)
File "E:\Python27\lib\site-packages\django\core\management\base.py", line 232, in execute
output = self.handle(*args, **options)
File "D:\YUNTU\Incubations\Project\chlitina\germes\lib\south\management\commands\migrate.py", line 111, in handle
ignore_ghosts = ignore_ghosts,
File "D:\YUNTU\Incubations\Project\chlitina\germes\lib\south\migration\__init__.py", line 220, in migrate_app
success = migrator.migrate_many(target, workplan, database)
File "D:\YUNTU\Incubations\Project\chlitina\germes\lib\south\migration\migrators.py", line 254, in migrate_many
result = migrator.__class__.migrate_many(migrator, target, migrations, database)
File "D:\YUNTU\Incubations\Project\chlitina\germes\lib\south\migration\migrators.py", line 329, in migrate_many
result = self.migrate(migration, database)
File "D:\YUNTU\Incubations\Project\chlitina\germes\lib\south\migration\migrators.py", line 133, in migrate
result = self.run(migration, database)
File "D:\YUNTU\Incubations\Project\chlitina\germes\lib\south\migration\migrators.py", line 114, in run
return self.run_migration(migration, database)
File "D:\YUNTU\Incubations\Project\chlitina\germes\lib\south\migration\migrators.py", line 84, in run_migration
migration_function()
File "D:\YUNTU\Incubations\Project\chlitina\germes\lib\south\migration\migrators.py", line 60, in <lambda>
return (lambda: direction(orm))
File "D:\YUNTU\Incubations\Project\chlitina\germes\app\weixin\wxwall\migrations\0002_auto__add_field_participation_event__add_field_scene_welcome_msg.py", line 17, in forwards
keep_default=False)
File "D:\YUNTU\Incubations\Project\chlitina\germes\lib\south\db\generic.py", line 47, in _cache_clear
return func(self, table, *args, **opts)
File "D:\YUNTU\Incubations\Project\chlitina\germes\lib\south\db\generic.py", line 418, in add_column
self.execute(sql)
File "D:\YUNTU\Incubations\Project\chlitina\germes\lib\south\db\generic.py", line 282, in execute
cursor.execute(sql, params)
File "E:\Python27\lib\site-packages\django\db\backends\util.py", line 40, in execute
return self.cursor.execute(sql, params)
File "E:\Python27\lib\site-packages\django\db\backends\mysql\base.py", line 114, in execute
return self.cursor.execute(query, args)
File "E:\Python27\lib\site-packages\MySQLdb\cursors.py", line 203, in execute
if not self._defer_warnings: self._warning_check()
File "E:\Python27\lib\site-packages\MySQLdb\cursors.py", line 117, in _warning_check
warn(w[-1], self.Warning, 3)
_mysql_exceptions.Warning: InnoDB: ROW_FORMAT=DYNAMIC requires innodb_file_format > Antelope.
解决方法:
我找到了问题.关键是innodb_file_format
我从生产数据库backup.Production的mysql配置innodb_file_format = Barracuda恢复数据,但我的本地是默认值Antelope.
我认为更合适的错误信息是ROW_FORMAT = DYNAMIC需要innodb_file_format = Barracuda.
我该怎么做才在my.ini中设置innodb_file_format = Barracuda,然后一切都会好的.
内容总结
以上是互联网集市为您收集整理的mysql – 南迁移错误,InnoDB:ROW_FORMAT = DYNAMIC需要innodb_file_format>羚羊全部内容,希望文章能够帮你解决mysql – 南迁移错误,InnoDB:ROW_FORMAT = DYNAMIC需要innodb_file_format>羚羊所遇到的程序开发问题。 如果觉得互联网集市技术教程内容还不错,欢迎将互联网集市网站推荐给程序员好友。
内容备注
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 gblab@vip.qq.com 举报,一经查实,本站将立刻删除。
内容手机端
扫描二维码推送至手机访问。