[SOLVED] Upgrade to 3.0.1 - Row size too large - MariaDB 10.5

Your software
My PHP version is : 7.3.20
My MariaDB version is : 10.5
Server version: 10.5.4-MariaDB MariaDB Server
Client: mysql Ver 15.1 Distrib 10.5.4-MariaDB, for Linux (x86_64) using readline 5.1

Updating/Installing Errors
I am : Updating from 2.16.3 to 3.0.1
Upgrading via : Command Line with command “php upgrade_v3.php --ignore-warnings” as my installation has more than 10000 contacts

These errors are showing in the installer :

 -> ALTER TABLE users DROP online_status

Migration 20200211095409 failed during Execution. Error An exception occurred while executing ‘ALTER TABLE users DROP online_status’:

SQLSTATE[42000]: Syntax error or access violation: 1118 Row size too large. The maximum row size for the used table type, not counting BLOBs, is 8126. This includes storage overhead, check the manual. You have to change some columns to TEXT or BLOBs

In AbstractMySQLDriver.php line 106:

An exception occurred while executing ‘ALTER TABLE users DROP online_status’:

SQLSTATE[42000]: Syntax error or access violation: 1118 Row size too large. The maximum row size for the used table type, not counting BLOBs, is 8126. This includes storage overhead, check the manual. You have to change some columns to
TEXT or BLOBs

In PDOConnection.php line 80:

SQLSTATE[42000]: Syntax error or access violation: 1118 Row size too large. The maximum row size for the used table type, not counting BLOBs, is 8126. This includes storage overhead, check the manual. You have to change some columns to
TEXT or BLOBs

In PDOConnection.php line 75:

SQLSTATE[42000]: Syntax error or access violation: 1118 Row size too large. The maximum row size for the used table type, not counting BLOBs, is 8126. This includes storage overhead, check the manual. You have to change some columns to
TEXT or BLOBs

These errors are showing in the Mautic log :

These errors are showing in the upgrade_log.txt file (located in the root of your Mautic instance when an upgrade has been attempted - ensure you remove or redact any sensitive data such as domain names in the file path) :

Same output there as in the console

Your problem
My problem is :

I’m unable to finish the upgrade and I think I’m stuck between version 2 and 3 of Mautic.

Steps I have tried to fix the problem :

I looked at other “Row size too large” problem reports and it seems the solution was always to upgrade to the latest version of MySQL/MariaDB. I’m running the latest stable version of MariaDB on my system (10.5) but I’m getting this error.
Any help is welcome…

After fiddling around I think I fixed the problem. I edited the MariaDB server config file (located in /etc/my.cnf.d/server.cnf) and added those 2 lines:

innodb_log_file_size=512M
innodb_strict_mode=0

This fixed the “Row size too large” error.

Now in order to get the upgrade script to run and resume the second stage I had to comment out the lines where it tries to copy files over (line 819 to 847). However once the upgrade script finished some Mautic v3 files were missing.

So I downloaded the 3.0.1 Mautic ZIP file https://github.com/mautic/mautic/releases/download/3.0.1/3.0.1.zip and extracted its content in my new Mautic 3 base directory.

I got a final bug where my browser was telling me I wasn’t authorized to access my Mautic web site. I fixed this by restoring the .htaccess file from my old Mautic 2 installation in the Mautic 3 base directory. (and then rewrite rules are working and I have Mautic 3 working fine)

Good luck everybody, I hope this helps someone hitting the same problems.

1 Like