How to Solve MariaDB Error Message ERROR 1709 (HY000) at line 1283: Index column size too large. The maximum column size is 767 bytes.

Posted on

How to solve the error message specified in the title of this article?, It is going to be shown in the following article written. The error is actually happened upon restoring a MySQL Database dump file into a MariaDB Database Server. The error itself is actually triggered after the error specified in the article titled ‘How to Solve MariaDB Error Message ERROR 1071 (42000) : Specified key was too long; max key length is 767 bytes’ in this link has already been solved. The error specified in the article stated previously is actually solved by adding the following line of configuration to the MariaDB configuration file :

innodb_large_prefix=on
innodb_file_format=Barracuda

But suddenly, after restarting MariaDB service, to implement the already added configurations, another different error triggered. The error is shown as follows :

[root@hostname mysql]# mysql -uroot moodle < /home/user/moodle-dump-file.sql 
ERROR 1709 (HY000) at line 1283: Index column size too large. The maximum column size is 767 bytes.
[root@hostname mysql]#

Another error shown as specified in the title of this article and also in the output of the above command generated :

ERROR 1709 (HY000) at line 1283: Index column size too large. The maximum column size is 767 bytes.

To be able to solve the problem so the error message generated can be handled and it can also be a final solution to be able to restore dump file generated from MySQL Database Server into a database exist and located in MariaDB, just edit the MariaDB configuration file located in ‘/etc/my.cnf’. Just edit it by adding the following line of configurations :

innodb_large_prefix=TRUE
innodb_file_per_table=TRUE

Just place the two additional lines above in the [mysqld] section. So, if the additional lines above inserted, the whole line configuration for solving the problem so that the restore process of MySQL Database dump file will be successfully carried out to the MariaDB database, and it can actually be shown as follows :

[mysqld]
innodb_large_prefix=TRUE
innodb_file_per_table=TRUE
innodb_large_prefix=on
innodb_file_format=Barracuda

Don’t forget to restart the MariaDB service by executing the following command :

service mariadb restart

or just restart it with any available means provided in the operating system. After restarting MariaDB service, just re-execute the command for restoring the database file acquired from MySQL Database Server where the version isĀ  MySQL Server version: 5.7.18 MySQL Community Server (GPL) into MariaDB with the version of 5.5.56-MariaDB.

Leave a Reply