mirror of
https://github.com/modoboa/modoboa-postfix-autoreply.git
synced 2026-04-25 08:35:53 +03:00
[GH-ISSUE #19] Migrate Index Column size too large #8
Labels
No labels
bug
bug
enhancement
enhancement
enhancement
pull-request
question
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/modoboa-postfix-autoreply-modoboa#8
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @msenebald on GitHub (Oct 26, 2015).
Original GitHub issue: https://github.com/modoboa/modoboa-postfix-autoreply/issues/19
Hi,
just updated to Postfix autoreply 1.1.1 and run the migrate.
But I get the following error.
I tried to find the migration file and check what it is trying to do but failed to do so.
Database is a InnoDB
Autoreply Schemas look like:
Thanks for any help.
BR Martin
@tonioo commented on GitHub (Nov 12, 2015):
Hi, unfortunately it seems to be a MySQL+InnoDB limitation (according to http://south.aeracode.org/ticket/39 and http://stackoverflow.com/questions/1814532/1071-specified-key-was-too-long-max-key-length-is-767-bytes.
I suggest you try this workaround: http://mechanics.flite.com/blog/2014/07/29/using-innodb-large-prefix-to-avoid-error-1071/.
Please tell me if it works.
@tonioo commented on GitHub (Nov 19, 2015):
@msenebald ping
@msenebald commented on GitHub (Jan 1, 2016):
Hi,
sorry for the delay. I tried the workaround, but without success.
Since i am not so familiar with django, i a not sure how to get the sql code that is generated by the migration.
What I did, I removed the index option in the migration "db_index=True" from:
migrations/0002_auto_20150728_1236.py
it happily upgrades the rest. But now without index.
I use mariadb 5.5.44 from official centos 7 repo.
@tonioo commented on GitHub (Jan 4, 2016):
Have you tried to recreate indexes after the migration ?
@tenninjas commented on GitHub (Feb 2, 2016):
This can be solved by changing max_length to 253, which would seem sensible since domain names cannot acceptably exceed 253 characters in any case.
@armouredking commented on GitHub (Feb 24, 2016):
The workaround you've noted ( large prefix ) only works with an additional two steps:
ROW_FORMAT.The second issue is generally what gets people. It's easy enough to switch over to Barracuda, but the
ROW_FORMAToption needs to be specified depending on your server setup. The defaultROW_FORMATis usually set toCOMPACT( even my latest edition install of MariaDB 10.1 was set toCOMPACT); you need to append theROW_FORMAT=DYNAMIC;or whatever you want to use to the actualCREATEline, like so:Or change your
ROW_FORMAT=DEFAULToption to useDYNAMICinstead ofREDUNDANTorCOMPACTif you'd rather not deal.COMPRESSEDcannot be set globally. ( Edit to note: This is only present in really really new versions. You probably don't have it - I don't. Explicitly setting the option is the only way atm ).For more information about
ROW_FORMATsee the manual.@msenebald commented on GitHub (Apr 1, 2016):
Perfect. Thanks for your help @tonioo !