Bug #848

MySQL DB creation fails because of key length

Added by Carlos Martín almost 10 years ago. Updated about 6 years ago.

Status:ClosedStart date:
Priority:NormalDue date:
Assignee:Carlos Martín% Done:

100%

Category:Core & System
Target version:Release 3.2 - S0
Resolution:fixed Pull request:
Affected Versions:OpenNebula 3.0

Description

As reported in the mailing list, the MySQL DB bootstrap fails for some installations.

The proposed solution is to change the size of some text columns:
http://lists.opennebula.org/pipermail/users-opennebula.org/2011-August/006260.html
http://lists.opennebula.org/pipermail/users-opennebula.org/2011-September/006545.html

Another way to solve this may be setting the charset to latin1, because the key length depends on the number of bytes per character.
http://dev.mysql.com/doc/refman/5.0/en/charset-applications.html


Subtasks

Feature #896: Develop onedb migratorClosedCarlos Martín

Associated revisions

Revision 21bca207
Added by Carlos Martín over 9 years ago

Bug #848: Add error message and stop oned execution if bootstrap fails

Revision 771a4ac8
Added by Carlos Martín over 9 years ago

Bug #848: Set name columns to 128 chars. The name length is checked for new objects

Revision ee28c22f
Added by Carlos Martín over 9 years ago

Bug #848: Fix tests

Revision ba8399c9
Added by Carlos Martín over 9 years ago

Bug #848: Add 3.1.0 migrator, it will truncate existing names with more than 128 chars.

Revision 057e2053
Added by Carlos Martín over 9 years ago

Bug #848: Fix tests

Revision 9ed5b738
Added by Carlos Martín over 9 years ago

Bug #848: Take into account bug #871, avoid table lock

History

#1 Updated by Robert Hennig almost 10 years ago

I don't think that setting the charset to latin1 is a proper solution as Latin1 does not contain all required chracters for some languages (compared to UTF-8).

I don't know much about the code so I can't tell if there is a real reason for these fields to be 256 chars long instead of 255. But if there is no real reason it would be best to just reduce the field sizes by one char.

#2 Updated by Ruben S. Montero almost 10 years ago

  • Target version changed from Release 3.4 to Release 3.2 - S0

#3 Updated by Ruben S. Montero over 9 years ago

  • Status changed from New to Closed
  • Resolution set to fixed

Size is now 128. Changes in master

Also available in: Atom PDF