[MDEV-6914] starting from 10.0.14 unmotivated "Row size too large (> 8126)..." on longtext Created: 2014-10-22  Updated: 2014-11-11  Resolved: 2014-10-23

Status: Closed
Project: MariaDB Server
Component/s: Storage Engine - InnoDB
Affects Version/s: 10.0.14, 10.1.1
Fix Version/s: N/A

Type: Bug Priority: Major
Reporter: Denis Kaganovich Assignee: Elena Stepanova
Resolution: Not a Bug Votes: 0
Labels: upstream

Attachments: File bug.sql     File my.cnf    

 Description   

starting from 10.0.14 (current git affected, 10.0.13 - no) unmotivated "Row size too large (> 8126)..." on longtext on dump-reload existing db. Full message:
"ERROR 1118 (42000) at line 55: Row size too large (> 8126). Changing some columns to TEXT or BLOB or using ROW_FORMAT=DYNAMIC or ROW_FORMAT=COMPRESSED may help. In current row format, BLOB prefix of 768 bytes is stored inline."

Attaching extracted part of dump, producing this. This is not longest string, even smaller was loades. Just bug.



 Comments   
Comment by Elena Stepanova [ 2014-10-23 ]

Hi Denis,

Please attach your cnf file(s) or output of SHOW VARIABLES from any of the servers where you are getting the error.

Thanks.

Comment by Elena Stepanova [ 2014-10-23 ]

Thank you, it helps.
As a workaround, please try to increase the value of innodb_log_file_size (it's now set to 5M in your cnf file).

Comment by Denis Kaganovich [ 2014-10-23 ]

Thanks, it works (innodb_log_file_size=64M). But still keep in mind there are dangerous versions, while cannot reload some dump...

Comment by Elena Stepanova [ 2014-10-23 ]

I'm not saying it's not a bug, just suggesting a workaround.
It's an upstream issue which got into 10.0 (and further into 10.1) with the merges of InnoDB from MySQL and XtraDB from Percona. I'm looking for the commit that caused it to understand whether it was intentional or not. After that, the normal routine is to report the problem upstream so they can fix, and we'll pull the fix along with the next engine merge.

Comment by Elena Stepanova [ 2014-10-23 ]

I found the revision that caused it, and the change appears to be intentional:
http://bazaar.launchpad.net/~mysql/mysql-server/5.6/revision/5958

revno: 5958
revision-id: annamalai.gurusami@oracle.com-20140522155303-y5bvfo4sq0tdls98
parent: marko.makela@oracle.com-20140522115539-2yijjno0m7n65i7o
committer: Annamalai Gurusami <annamalai.gurusami@oracle.com>
branch nick: mysql-5.6
timestamp: Thu 2014-05-22 21:23:03 +0530
message:
  Bug #16963396 INNODB: USE OF LARGE EXTERNALLY-STORED FIELDS MAKES CRASH
  RECOVERY LOSE DATA
  
  Problem:
  
  When too-large blob fields are used, InnoDB overwrites its most recent
  checkpoint in its redo logs.
  
  Solution:
  
  Ensure that the total blob length does not exceed 10% of the redo log file
  size.
  
  rb#5399 approved by Marko, Nuno, Manish. 
  Venkat also contributed to patch (in replication related test case).

Your data is some 770 Kb, the log file is 5 Mb, so it all fits.

I don't think ti's wise to change the behavior in MariaDB, it will probably cause more incompatibility than it solves. If you feel strong about it, please try to report it upstream at bugs.mysql.com, and if they decide to fix it we'll merge. If you do so, please comment here so that we re-open this issue and keep it open until the fix arrives.

Comment by Denis Kaganovich [ 2014-10-24 ]

Yes, also I see - it is fixed unlimited upstream in 5.7. So, just hope to mering 5.7.

Comment by Meik Suchlich [ 2014-11-11 ]

In which Version will the fix be available?
How do we get the information?

Comment by Elena Stepanova [ 2014-11-11 ]

Whichever major version declares inclusion of InnoDB 5.7 should have it.
When it happens highly depends on the upstream release cycle – until MySQL 5.7 is officially stable (GA), InnoDB won't be merged because it changes too much from release to release.
If 5.7 goes GA before 10.1 does, or preferably before 10.1 is RC, there is a good chance InnoDB 5.7 will be included into it. Otherwise it should be 10.2.

Comment by Meik Suchlich [ 2014-11-11 ]

well, that's very bad, because the bug is in actual release. How can we work around it?
What is the impact of this failure?
Does it work to add --force to the import-parameters?
It seems so, because the data where the error is thrown is in the table. And thats what I don't understand. I expected, that the data would be stepped over.

Comment by Meik Suchlich [ 2014-11-11 ]

can someone put the reference to the mysql-bug in here.

Comment by Elena Stepanova [ 2014-11-11 ]

If you read previous comments, specifically the commit comment for the upstream revision, you'll see that it was an intentionally introduced limitation. My guess is that's what the InnoDB team had to come up with in order to fix the recovery crash without making too intrusive changes in a post-GA version.
The workaround should be to shutdown the server gracefully, increase the value of innodb_log_file_size to make it definitely greater than 10x(total blog length), and to start the server again.

That said, it looks like in InnoDB 5.6.22 the limitation is a bit relaxed (although not completely removed like in 5.7). InnoDB 5.6.22 will most likely be in 10.0.16 – doubt it will make it to 10.0.15 since 5.6.22 has not been released yet..

The upstream bug they were solving is http://bugs.mysql.com/bug.php?id=69477

Comment by Meik Suchlich [ 2014-11-11 ]

Is there a chance to get back to 10.0.13 (with debian/ubuntu repository?) or is the bug in there to?

Comment by Elena Stepanova [ 2014-11-11 ]

You can find 10.0.13 in the repo, e.g. ftp://ftp.osuosl.org/pub/mariadb/mariadb-10.0.13/repo/ (the repo that you are using is likely to have a similar path).
But really, increasing the value of innodb_log_file_size is much simpler, and it's the right thing to do anyway if you have big blobs, otherwise your server is potentially affected by bug#69477 which might cause real damage.

Comment by Meik Suchlich [ 2014-11-11 ]

which log_file_size should we set?
we have blobs which might be over 100MB...

Comment by Elena Stepanova [ 2014-11-11 ]

The max allowed value for innodb_log_file_size is 512GB / innodb_log_files_in_group , so you have enough room for the maneuver.
Big redo files might make crash recover slower, but since your crash recovery is affected by the bug anyway, it shouldn't be a critical reason not to increase them.

Generated at Thu Feb 08 07:15:33 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.