| Bug #113002 | innodb.ddl_kill test fails sporadically. | ||
|---|---|---|---|
| Submitted: | 8 Nov 2023 8:32 | Modified: | 27 Sep 2024 22:18 |
| Reporter: | Dmitry Lenev (OCA) | Email Updates: | |
| Status: | Closed | Impact on me: | |
| Category: | MySQL Server: InnoDB storage engine | Severity: | S3 (Non-critical) |
| Version: | 8.0.35 | OS: | Linux |
| Assigned to: | CPU Architecture: | Any | |
| Tags: | Contribution | ||
[8 Nov 2023 8:47]
Dmitry Lenev
Simple fix for sporadic innodb.ddl_kill failures. (*) I confirm the code being submitted is offered under the terms of the OCA, and that I am authorized to contribute it.
Contribution: ps-8671-bug113002-contrib.patch (text/x-patch), 3.38 KiB.
[8 Nov 2023 9:29]
MySQL Verification Team
Hello Dmitry, Thank you for the report and contribution. regards, Umesh
[8 Nov 2023 10:34]
Dmitry Lenev
Hello! Additional note about the approach used to fix this issue in the contribution. InnoDB team might consider alternative approach and add THD objects for worker threads created by parallel ALTER TABLE implementation so it works better with DEBUG_SYNC facility. After all InnoDB already creates THD objects for some of its background threads. I have considered this approach but decided that I am not feeling confident with InnoDB code enough to follow it.
[22 Jul 2024 10:35]
Rahul Sisondia
Posted by developer: Hello Dmitry, Thank you for contribution and analysis. I see that proposed patch fix the test failure correctly. I shall try to squeeze the fix.
[27 Sep 2024 22:18]
Philip Olson
Posted by developer: Fixed as of the upcoming MySQL Server 8.0.40, 8.4.3, and 9.1.0 releases, and here's the proposed changelog entry from the documentation team for review: Fixed an innodb.parallel_read_kill related unit test to better account for recent optimizer changes, and fixed an innodb.ddl_kill unit test and its associated macro usage. Our thanks to Dmitry Lenev and the team at Percona for contributing to these fixes. Thank you for the bug report. This entry was combined with the fix for MySQL Bug #115416.

Description: innodb.ddl_kill test case fails sporadically when run against debug version of server (this test is skipped on non-debug build). The problem seems to be caused by combination a) wrong macro used in InnoDB code to set debug sync point used by this test and b) missing cleanup between different parts of test case. How to repeat: Run: ./mtr --mem --repeat=100 ddl_kill against debug version of server. For me even the first iteration fails typically with: Logging: XXX/mysql-test/mysql-test-run.pl --mem --repeat=100 ddl_kill MySQL Version 8.0.35 Checking supported features - Binaries are debug compiled Using 'all' suites Collecting tests Checking leftover processes Removing old var directory Creating var directory 'XXX/mysql-test/var' - symlinking 'var' to '/dev/shm/var_auto_IKMu' Installing system database Using parallel: 1 ============================================================================== TEST NAME RESULT TIME (ms) COMMENT ------------------------------------------------------------------------------ [ 0%] innodb.ddl_kill [ fail ] Test ended at 2023-11-08 09:14:24 CURRENT_TEST: innodb.ddl_kill mysqltest: At line 60: Query 'reap' succeeded, should have failed with error '1317' ... Suggested fix: I plan to contribute simple fix for this problem.