[MDEV-3815] Aria engine return "The table is full" (ERROR 1114) inserting record, while MyISAM and InnoDB doesn't Created: 2012-10-19 Updated: 2014-03-10 Resolved: 2014-03-10 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | None |
| Affects Version/s: | 5.5.27, 5.5.25-galera |
| Fix Version/s: | 10.0.10 |
| Type: | Bug | Priority: | Major |
| Reporter: | Risato Stefano | Assignee: | Michael Widenius |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Environment: |
Windows server 2003 enterprise 32 bit |
||
| Description |
|
Trying to convert a 9GB InnoDB table to Aria engine, I get the error 1114 when the .MAD file reaches 4GB (.MAI is 500MB). The table is DYNAMIC, with 134 fields, PK is INT, and other 3 indexes is CHAR(11),CHAR(25) and TIMESTAMP. The problem doesn't occour if I convert to MyISAM (the result table is bigger than 4GB). Same problem with another table. |
| Comments |
| Comment by Elena Stepanova [ 2012-11-27 ] | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
As Sergei answered in the KB ( https://kb.askmonty.org/en/aria-max-table-size/ ), the workaround is to use an explicit value of MAX_ROWS table option. I can confirm both the described problem and the workaround, see the output below. However, I'm not sure it's quite reasonable to require the option in this case. We don't create a table, but alter it. The table already contains the given number of rows, so one could expect that MAX_ROWS would be considered at least this big. I will assign it to Monty to decide if anything can and should be done about it, maybe in upcoming 10.x release, if not earlier. Output:
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Risato Stefano [ 2012-11-28 ] | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
I confirm that the workaround is ok. However I do not understand the usefulness of the max_rows option... | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Michael Widenius [ 2014-01-26 ] | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Hi! MAX_ROWS gives information to the Aria engine how many rows there will be in the table. The current assumption is to use 4 byte pointers, which for dynamic row files gives a maximum of 4G. For static size rows a 4 byte pointer would give you 4G rows. I will change Aria so that by default, if max_rows is not given, it will use 6 byte pointers. That should be enough for most cases. | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Michael Widenius [ 2014-01-27 ] | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
I have now fixed the pointers and tested this, seams to work. I am reasonable sure the changes to maria_records_in_range() are correct (spent several hours testing this), but I don't want to do this change in a stable version. I will first push the change to MariaDB 10.0. If we don't find any issues with this for a while and this is still found to be critical for 5.5 users I can then backport this to 5.5. This will be pushed to 10.0 later this week. | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Michael Widenius [ 2014-02-11 ] | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Fix pushed into 10.0-monty tree. Will be merged to 10.0 soon | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Michael Widenius [ 2014-03-10 ] | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Pushed some time ago into 10.0 tree |