Bug #47902 | partition_recover_myisam fails with --ps-protocol | ||
---|---|---|---|
Submitted: | 7 Oct 2009 20:12 | Modified: | 29 Jan 2011 23:06 |
Reporter: | Sergey Petrunya | Email Updates: | |
Status: | Closed | Impact on me: | |
Category: | MySQL Server | Severity: | S3 (Non-critical) |
Version: | 5.1-bzr, current | OS: | Linux (Ubuntu 9.04 x86) |
Assigned to: | Mattias Jonsson | CPU Architecture: | Any |
[7 Oct 2009 20:12]
Sergey Petrunya
[7 Oct 2009 20:43]
MySQL Verification Team
On Windows: vardir: c:/build/mysql-5.1/mysql-test/var Checking leftover processes... - found old pid 4532 in 'mysqld.1.pid', killing it... process did not exist! Removing old var directory... Creating var directory 'c:/build/mysql-5.1/mysql-test/var'... Installing system database... Using server port 51593 ============================================================================== TEST RESULT TIME (ms) ------------------------------------------------------------ worker[1] Using MTR_BUILD_THREAD 300, with reserved ports 13000..13009 parts.partition_recover_myisam [ fail ] Test ended at 2009-10-07 17:42:04 CURRENT_TEST: parts.partition_recover_myisam --- c:/build/mysql-5.1/mysql-test/suite/parts/r/partition_recover_myisam.result Mon Sep 21 08:44:44 2009 +++ c:\build\mysql-5.1\mysql-test\suite\parts\r\partition_recover_myisam.reject Wed Oct 07 17:42:03 2009 @@ -18,13 +18,6 @@ 9 10 11 -Warnings: -Error 145 Table './test/t1_will_crash' is marked as crashed and should be repaired
[7 Oct 2009 20:46]
MySQL Verification Team
Thank you for the bug report.
[9 Oct 2009 0:36]
Omer Barnir
triage: setting to SR51TEST - assuming the test is at fault but might be a server issue - not clear how the 'crashed table ' is crated
[10 Jan 2011 21:13]
Mattias Jonsson
The diff is because that the warnings is created in the prepare phase before the execution, and if mysql_stmt_result_metadata(stmt) succeeded (!= NULL) those errors where cleared. This patch fixes that: === modified file 'client/mysqltest.cc' --- client/mysqltest.cc 2010-12-19 17:07:28 +0000 +++ client/mysqltest.cc 2011-01-10 21:02:20 +0000 @@ -7241,8 +7241,10 @@ mysql_free_result(res); /* Free normal result set with meta data */ +#ifdef bug47902 /* Clear prepare warnings */ dynstr_set(&ds_prepare_warnings, NULL); +#endif bug47902 } else {
[10 Jan 2011 22:44]
Bugs System
A patch for this bug has been committed. After review, it may be pushed to the relevant source trees for release in the next version. You can access the patch from: http://lists.mysql.com/commits/128362 3539 Mattias Jonsson 2011-01-10 Bug#47902: partition_recover_myisam fails with --ps-protocol The problem was that the warnings was never written out when running with --ps-protocol. This was because the warnings only appeared during the prepare phase, not the execute phase. Solved by not clearing the warnings from the prepare phase if there was no other warnings. If there are warnings from the execute phase, it is very likely to be the same as from the prepare phase. My tests show that if not clearing the warnings from the prepare phase when there are warnings from the execute phase, there will be duplicated warnings in the result. @ client/mysqltest.cc Only reset the prepare warnings if there are warnings from the execute phase. Otherwise these warnings will never be returned.
[11 Jan 2011 15:41]
Bjørn Munch
This looks good, have also tested it.
[12 Jan 2011 12:06]
Bjørn Munch
Bug #21089 closed as duplicate of this.
[26 Jan 2011 20:15]
Bugs System
Pushed into mysql-trunk 5.6.2 (revid:mattias.jonsson@oracle.com-20110126201331-ab82uv7s5qmdufs5) (version source revid:mattias.jonsson@oracle.com-20110126201331-ab82uv7s5qmdufs5) (merge vers: 5.6.2) (pib:24)
[26 Jan 2011 20:16]
Bugs System
Pushed into mysql-5.5 5.5.10 (revid:mattias.jonsson@oracle.com-20110126183353-8fngni1uuyybmz9u) (version source revid:mattias.jonsson@oracle.com-20110126183353-8fngni1uuyybmz9u) (merge vers: 5.5.10) (pib:24)
[26 Jan 2011 20:16]
Bugs System
Pushed into mysql-5.1 5.1.56 (revid:mattias.jonsson@oracle.com-20110126155021-evjpfdciphnd50sy) (version source revid:mattias.jonsson@oracle.com-20110126153434-z7k5auijsepxhdss) (merge vers: 5.1.56) (pib:24)
[26 Jan 2011 23:45]
Paul DuBois
Test suite change. No changelog entry needed.