Bug #29957 alter_table.test fails
Submitted: 22 Jul 2007 14:16 Modified: 30 Jul 2007 21:22
Reporter: Ingo Strüwing
Status: Closed
Category:Server: General Severity:S2 (Serious)
Version:5.1.21, 5.2.5 OS:Microsoft Windows
Assigned to: Sergey Vojtovich Target Version:
Tags: pbfail

[22 Jul 2007 14:16] Ingo Strüwing
Description:
main.alter_table               [ fail ]

Errors are (from e:/var-ps_row-121/log/mysqltest-time) :
mysqltest: Result length mismatch
(the last lines may be the most important ones)
Below are the diffs between actual and expected results:
-------------------------------------------------------
***
C:/cygwin/home/pushbuild/pb3/pb/mysql-5.2-engines/9/mysql-5.2.5-alpha-pb9/mysql-test/r/alt
er_table.result	Sun Jul 22 00:53:04 2007
---
C:/cygwin/home/pushbuild/pb3/pb/mysql-5.2-engines/9/mysql-5.2.5-alpha-pb9/mysql-test/r/alt
er_table.reject	Sun Jul 22 01:06:24 2007
***************
*** 1030,1036 ****
  c
  NULL
  1
- Two
  Three
  lock table t2 write, t3 read;
  alter table t2 change c vc varchar(100) default "Four", rename to t1;
--- 1030,1035 ----
***************
*** 1047,1053 ****
  vc
  NULL
  1
- Two
  Three
  Four
  drop tables t1, t3;
--- 1046,1051 ----
-------------------------------------------------------
Please follow the instructions outlined at

Thare is a small chance that it might be related to a bad merge. However it is not obvious
why this should fail on Windows only.

But it fails on Windows only and on all Windows machines included in pushbuild for
5.2-engines. So there is a high probability that it is a Windows specific problem.

How to repeat:
Please see pushbuild push Sat Jul 21 23:37:49 2007 istruewing on
https://intranet.mysql.com/secure/pushbuild/showdir.pl?dir=mysql-5.2-engines
[23 Jul 2007 11:24] Sergey Vojtovich
Stealing this one, as it was likely caused by my fix.
[23 Jul 2007 11:35] Ingo Strüwing
Ah yes, it does also fail in 5.1.
[26 Jul 2007 13:21] 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/31610

ChangeSet@1.2531, 2007-07-26 15:24:09+05:00, svoj@mysql.com +3 -0
  BUG#29957 - alter_table.test fails
  
  INSERT/DELETE/UPDATE followed by ALTER TABLE within LOCK TABLES
  may cause table corruption on Windows.
  
  That happens because ALTER TABLE writes outdated shared state
  info into index file.
  
  Fixed by updating shared state info prior to actually writing it
  to disk.
  
  Affects MyISAM tables on Windows only.
[27 Jul 2007 12:28] 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/31686

ChangeSet@1.2531, 2007-07-27 14:30:25+05:00, svoj@mysql.com +3 -0
  BUG#29957 - alter_table.test fails
  
  INSERT/DELETE/UPDATE followed by ALTER TABLE within LOCK TABLES
  may cause table corruption on Windows.
  
  That happens because ALTER TABLE writes outdated shared state
  info into index file.
  
  Fixed by removing obsolete workaround.
  
  Affects MyISAM tables on Windows only.
[27 Jul 2007 18:48] Bugs System
Pushed into 5.1.21-beta
[27 Jul 2007 18:50] Bugs System
Pushed into 5.0.48
[30 Jul 2007 21:22] Paul DuBois
Noted in 5.0.48, 5.1.21 changelogs.

For MyISAM tables on Windows, INSERT, DELETE, or UPDATE followed by
ALTER TABLE within LOCK TABLES could cause table corruption.