[MDEV-25789] Bug report: abortion in table_file_summary_by_instance.cc:0 Created: 2021-05-27 Updated: 2022-02-09 Resolved: 2022-02-09 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | Optimizer |
| Affects Version/s: | 10.5.9 |
| Fix Version/s: | N/A |
| Type: | Bug | Priority: | Critical |
| Reporter: | Zuming Jiang | Assignee: | Sergei Golubchik |
| Resolution: | Cannot Reproduce | Votes: | 0 |
| Labels: | crash | ||
| Environment: |
Ubuntu 18.04 |
||
| Attachments: |
|
| Description |
|
I used my fuzzing tool to test Mariadb , and found a bug that can result in an abortion. Mariadb installation: How to Repeat: I have tried to simplify the content of fuzz.sql, but fuzz.sql was too complex. I hope fuzz.sql can help you reproduce the bug and fix it. In addition, I attach the abortion report (which has its stack trace). |
| Comments |
| Comment by Daniel Black [ 2021-05-27 ] | |||||||||||||||||
|
Zuming Jiang, I'm really appreciating seeing these bug reports. Does your fuzzing tool fit into the framework of what https://github.com/google/oss-fuzz can do in an automated way? On this report, I'm unable to reproduce it in the current 10.5 build tree at commit 288b8016961e390ca71dd4657efdfcec388f1494. I am however using clang++ --version Since you are mostly on a build yourself, allow me to show you how I've tested the latest 10.5 version. The 10.X major versions of the MariaDB source tree should always be very stable.
To test without installing starting in the build directory:
To test from build dir:
To get a more complete stack once you have your fuzz:
The run the fuzz (client test). When the gdb run of the server halts at the assertion use the gdb command "bt full" to get a complete backtrace with the function arguments. | |||||||||||||||||
| Comment by Daniel Black [ 2021-05-27 ] | |||||||||||||||||
|
Other gdb techniques are documented in https://mariadb.com/kb/en/how-to-produce-a-full-stack-trace-for-mysqld/#getting-backtraces-with-gdb-on-linux Are you using the default ubuntu-18.04 gcc compiler to produce this? Does it produce on the latest 10.5 branch for you? Thank you so much for these bug reports. I hope to one day soon finish reading your research paper(s). | |||||||||||||||||
| Comment by Vladislav Vaintroub [ 2021-05-27 ] | |||||||||||||||||
|
-DWTH_DEBUG=ON does not have any effect on MariaDB -DCMAKE_BUILD_TYPE=Debug | |||||||||||||||||
| Comment by Zuming Jiang [ 2021-05-27 ] | |||||||||||||||||
|
I am really so happy that my work can contribute to the development of MariaDB and get your appreciation. Actually, my fuzzing tool is not open-source yet, but I hope it can be used publicly in the future after I finish my research project about testing DBMSs. However, if any new bug is found by my fuzzing tools, I will report it. Thanks for your suggestion about testing and configuration. However, my fuzzing tool is still running and keeps finding new bugs, so I think it is not suitable to stop my fuzzing tool. As a result, I cannot reconfigure my build of MariaDB. Actually I can reliably reproduce this bug in MariaDB 10.5.9. Maybe this bug is fixed by the difference between 10.5 and 10.5.9. | |||||||||||||||||
| Comment by Vladislav Vaintroub [ 2021-05-27 ] | |||||||||||||||||
|
I only point out that WITH_DEBUG=ON does not work for MariaDB. | |||||||||||||||||
| Comment by Daniel Black [ 2021-05-27 ] | |||||||||||||||||
|
I'm happy to see fuzzing continue on non-debug builds. After all they are more production like. So sure, keep burning the cpu cycles on 10.5.9. A quick sanity check against the non-installed latest-10.5 could save some reporting time. | |||||||||||||||||
| Comment by Alice Sherepa [ 2021-05-27 ] | |||||||||||||||||
|
Zuming Jiang, I could not reproduce it on 10.5.9, could you please recheck if some options were used or smth | |||||||||||||||||
| Comment by Zuming Jiang [ 2021-05-27 ] | |||||||||||||||||
|
Hi alice, it seems strange because I can reproduce this bug reliably. Maybe there are some problems in my environment. I will try to use another computer to reproduce this bug. |