Articles in this section

Can't import database: Index column size too large. The maximum column size is 767 bytes

Plesk for Linux kb: technical

Applicable to:

  • Plesk for Linux

Symptoms

Importing a database fails with the following error:

Failed to create tmp table example_table. Index column size too large. The maximum column size is 767 bytes.

Cause

There are insufficient InnoDB values configured in MariaDB.

Resolution

Increase the InnoDB values directly on the server files; steps vary by OS.

   
CentOS/RHEL-based
   
  1. Connect to the server via SSH

  2. Edit /etc/my.cnf with the following

    innodb_default_row_format = dynamic
    innodb_large_prefix = 1

  3. Restart MariaDB to apply the changes

    # systemctl restart mariadb

   
Ubuntu/Debian
   
  1. Connect to the server via SSH

  2. Edit /etc/mysql/my.cnf with the following

    innodb_default_row_format = dynamic
    innodb_large_prefix = 1

  3. Restart MariaDB to apply the changes

    # systemctl restart mariadb

Was this article helpful?

Comments

0 comments

Please sign in to leave a comment.