[MDEV-27753] Incorrect ENGINE type of table after crash for CONNECT table Created: 2022-02-05 Updated: 2022-03-14 Resolved: 2022-03-14 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | Partitioning |
| Affects Version/s: | 10.6.4 |
| Fix Version/s: | 10.3.35, 10.4.25, 10.5.16, 10.6.8, 10.7.4, 10.8.3 |
| Type: | Bug | Priority: | Major |
| Reporter: | Mathew | Assignee: | Sergei Golubchik |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Environment: |
Debian |
||
| Description |
|
We had a mariadb crash today due to out of disk. After restoring the server all CONNECT tables had become ENGINE=SEQUENCE in their definition. Example schema:
After crash:
I've checked a few things, the frm file has a refernce to CONNECT and the header doesnt indicate a Sequence either.
My guess is that it's the table repair process? |
| Comments |
| Comment by Sergei Golubchik [ 2022-02-07 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
was mariadb that crashed and mariadb that you started after the crash exactly the same executable? Or have you upgraded mariadb meanwhile and the first and second outputs were created by different mariadb versions? | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Mathew [ 2022-02-07 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Same version, same configuration. Crash was caused by disk being full not On Tue, 8 Feb 2022, 5:23 am Sergei Golubchik (Jira), <jira@mariadb.org> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Mathew [ 2022-02-08 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
On further testing I can confirm that any crash triggers the bug, not just out of disk. This was tested for by purposefully causing an OOM in a testing environment. After automatic restart (by systemd) CONNECT table types had changed to SEQUENCE. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Sergei Golubchik [ 2022-02-09 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
can you attach one of these frm's ? | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Mathew [ 2022-02-09 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Sergei, CONNECT frm's include mysql passwords. Please create your own frm's using the provided schema. Please also note I long since fixed the crash (ALTER TABLE) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Sergei Golubchik [ 2022-02-15 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Unfortunately, I failed to repeat this using the provided schema. Here's my test case, for the reference
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Mathew [ 2022-02-16 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Thats one crazy transition list. Not sure how you expect to get feedback from a reporter in a few in a few miutes. Anyway I repeated a test on a install and import of schema on a Cloud VM and replicated issue after a dd to fill the disk. OS Debian bullseye (latest stable), not a fresh VM however. That makes three seperate systems I've replicated this on now. I'm going to do one final test on a fresh VM when I have a free moment. however at this point I'm less than impressed. How many defects that get reported are arbitarily closed in this bug tracker I wonder? | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Mathew [ 2022-02-16 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Fresh Debian Buster (Linode). 1. Install Repostories
9. This started to return table is full errors, rather than crashing (sometimes it crashes, sometimes it errors - either way). As this time it didnt crash on insert to full disk (usually it does, probably to do with binary log) I did a DDL operation (which usually crashes if the disk is full). "DROP TABLE test" this crashed mariadb successfully. 10. Delete disk occupying file 11. Restart mariadb (it has crashed). systemctl restart mariadb 12. Check table
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Sergei Golubchik [ 2022-02-16 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Oh, the status isn't cut in the stone. You provided more feedback — I'll reopen the bug report, no problem. Thanks will try again with the new info. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Mathew [ 2022-02-16 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
It does need to be a proper crash of mysql kill -9 / kill -11 does NOT cause the issue. So I'm not sure I can do for example a shell script to replicate. I tested killall -11 10 times in a loop with no luck. Disk full crashes have the highest rate of replicating this issue (not 100%). Perhaps the table has to be in the table cache or pending some frm write? I'm not certain what I should be trying here (this isnt an area of the mariadb engine that is familar to me). The hardest part of replicating this is making mariadb crash on demand. I have however managed to corrupt the database once while creating out of space crashes Not sure if related so I'll include it here.
It's beyond me so i'll do a fresh install with a reset the DB for any further testing |