[MDEV-13424] InnoDB: Assertion failure in file row0mysql.cc line 691 Created: 2017-08-02 Updated: 2020-08-07 Resolved: 2020-08-07 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | Storage Engine - InnoDB, Storage Engine - XtraDB |
| Affects Version/s: | None |
| Fix Version/s: | N/A |
| Type: | Bug | Priority: | Major |
| Reporter: | Jan Lindström (Inactive) | Assignee: | Thirunarayanan Balathandayuthapani |
| Resolution: | Cannot Reproduce | Votes: | 2 |
| Labels: | None | ||
| Attachments: |
|
| Comments |
| Comment by Jan Lindström (Inactive) [ 2017-08-08 ] | |||||||||||||||||||||||||||
|
Error code 20 seen on row_mysql_handle_errors function is DB_MISSING_HISTORY i.e. required history data has been deleted due to lack of space in rollback segment. This path of the code is not changed between 10.0 and 10.1. After successful restart there is again buffer overflow message.
But any of these cases have not really changed between 10.0 and 10.1. | |||||||||||||||||||||||||||
| Comment by Jan Lindström (Inactive) [ 2017-08-10 ] | |||||||||||||||||||||||||||
|
Selecting a row i.e. row0sel.cc could return this error message if !prebuilt->index_usable, do not see any reason to crash, I will add error handling for this case and add some error diagnostics if row version is not found for some reason. | |||||||||||||||||||||||||||
| Comment by Jan Lindström (Inactive) [ 2017-08-11 ] | |||||||||||||||||||||||||||
|
https://github.com/MariaDB/server/commit/7a4281d1b1b30c1ea76ec557a4a7f0c2e8d64e82 | |||||||||||||||||||||||||||
| Comment by Marko Mäkelä [ 2017-08-11 ] | |||||||||||||||||||||||||||
|
Like I wrote on GitHub, I think that we must first repeat the problem. The submitted patch may be useful in that, but it must not be pushed to the main branches in its current form. Does the problem repeat with both InnoDB and XtraDB? I believe that prebuilt->index_usable should always hold in row_mysql_handle_errors(), because that flag is being checked before we enter any low-level operations. The error DB_MISSING_HISTORY should never be returned from the low-level operations. The only low-level operation that can return it is row_vers_build_for_consistent_read() when trx_undo_prev_version_build() fails. And the only failure path is this one:
It maps to this one:
I am afraid that the problem could be that the purge view is advancing prematurely. This is a very serious problem. The read view of the oldest active transaction should always be protected from purge. If this is an XtraDB specific problem, could it be that XtraDB is violating this purge constraint? After all, XtraDB introduced parameters like innodb_kill_idle_transaction. | |||||||||||||||||||||||||||
| Comment by Axel Schwenke [ 2018-02-01 ] | |||||||||||||||||||||||||||
|
I've hit the same error while benchmarking commit bc7a1dc1fbd27e6064d3b40443fe242397668af7 Error log:
Stack trace:
Full stack trace attached. | |||||||||||||||||||||||||||
| Comment by Axel Schwenke [ 2018-02-01 ] | |||||||||||||||||||||||||||
|
How to reproduce:
The last line runs forever, it stops producing results after ~30 seconds. Then mysqld is crashed. sysbench-mariadb is https://github.com/hgxl64/sysbench-mariadb my.cnf and Lua scripts are attached. | |||||||||||||||||||||||||||
| Comment by Axel Schwenke [ 2018-02-02 ] | |||||||||||||||||||||||||||
|
the 10.3 branch is good up to (including) commit c0d5d7c | |||||||||||||||||||||||||||
| Comment by Jan Lindström (Inactive) [ 2018-02-05 ] | |||||||||||||||||||||||||||
|
marko I assigned this to you as you know this part of the code better than me. | |||||||||||||||||||||||||||
| Comment by Sergey Vojtovich [ 2018-02-14 ] | |||||||||||||||||||||||||||
|
10.3 regression is to be fixed within the scope of | |||||||||||||||||||||||||||
| Comment by Marko Mäkelä [ 2018-03-14 ] | |||||||||||||||||||||||||||
|
jplindst, I am reassigning this back to you until we have a reproducible test case for the originally reported bug. There was a bug that was introduced by | |||||||||||||||||||||||||||
| Comment by Thirunarayanan Balathandayuthapani [ 2020-08-07 ] | |||||||||||||||||||||||||||
|
I think this issue could have fixed by |