Bug #27044 | replicated with unique field ndb table allows duplicate key inserts | ||
---|---|---|---|
Submitted: | 12 Mar 2007 11:47 | Modified: | 2 Jun 2007 14:35 |
Reporter: | Andrei Elkin | Email Updates: | |
Status: | Closed | Impact on me: | |
Category: | MySQL Cluster: Replication | Severity: | S3 (Non-critical) |
Version: | 5.1.17 | OS: | Any |
Assigned to: | Andrei Elkin | CPU Architecture: | Any |
[12 Mar 2007 11:47]
Andrei Elkin
[12 Mar 2007 19:11]
Andrei Elkin
Checked other engine to conclude that ndb only is vulnerable. The patch is coming soon.
[13 Mar 2007 10:20]
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/21790 ChangeSet@1.2472, 2007-03-13 12:18:57+02:00, aelkin@dsl-kpogw6-fe8ddc00-181.dhcp.inet.fi +3 -0 Bug#27044 replicated with unique field ndb table allows duplkey inserts The bug in that slave version of a table with unique field still was able to execute INSERT query as replace whereas it's impossible on master. The reason of this artifact is lack of resetting of extra() [see files' comments]
[13 Mar 2007 10:20]
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/21791 ChangeSet@1.2472, 2007-03-13 11:38:06+02:00, aelkin@dsl-kpogw6-fe8ddc00-181.dhcp.inet.fi +3 -0 Bug#27044 replicated with unique field ndb table allows duplkey inserts The bug in that slave version of a table with unique field still was able to execute INSERT query as replace whereas it's impossible on master. The reason of this artifact is lack of resetting of extra() [see files' comments]
[15 Mar 2007 18:36]
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/22043 ChangeSet@1.2472, 2007-03-15 20:35:36+02:00, aelkin@dsl-hkibrasgw1-ff1ec100-106.dhcp.inet.fi +3 -0 Bug#27044 replicated with unique field ndb table allows duplkey inserts The bug in that slave version of a table with unique field still was able to execute INSERT query as replace whereas it's impossible on master. The reason of this artifact is wrong usage of ndb->extra:s. Fixed with leaving in do_before only table->file->extra(HA_EXTRA_WRITE_CAN_REPLACE); and reseting in do_after.
[19 Mar 2007 8:36]
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/22233 ChangeSet@1.2472, 2007-03-19 10:35:20+02:00, aelkin@dsl-hkibrasgw1-ff1ec100-106.dhcp.inet.fi +3 -0 Bug#27044 replicated with unique field ndb table allows duplkey inserts The bug in that slave version of a table with unique field still was able to execute INSERT query as replace whereas it's impossible on master. The reason of this artifact is wrong usage of ndb->extra:s. Fixed with resetting flags in do_before. There is open issue with symmetrical resetting table->file->extra(HA_EXTRA_NO_IGNORE_NO_KEY) which i had to omit due to the issue reported as bug#27077
[22 Mar 2007 12:04]
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/22625 ChangeSet@1.2447, 2007-03-22 13:17:08+01:00, tomas@whalegate.ndb.mysql.com +2 -0 BUG#27044 bug fix of 27320 fixes this, added test case
[2 May 2007 9: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/25891 ChangeSet@1.2472, 2007-05-02 12:44:26+03:00, aelkin@dsl-hkibras1-ff18c300-219.dhcp.inet.fi +3 -0 Bug#27044 replicated with unique field ndb table allows duplkey inserts The bug in that slave version of a table with unique field still was able to execute INSERT query as replace whereas it's impossible on master. The reason of this artifact is wrong usage of ndb->extra:s. Fixed with resetting flags at do_after. There is open issue with symmetrical resetting table->file->extra(HA_EXTRA_NO_IGNORE_NO_KEY) which i had to hand to bug#27077.
[2 May 2007 14:27]
Andrei Elkin
The last committed patch is for review.
[27 May 2007 12:20]
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/27406 ChangeSet@1.2472, 2007-05-27 15:20:20+03:00, aelkin@dsl-hkibras1-ff5dc300-70.dhcp.inet.fi +1 -0 Bug#27044 replicated with unique field ndb table allows duplkey inserts The bug in that slave version of a table with unique field still was able to execute INSERT query as replace whereas it's impossible on master. The reason of this artifact is wrong usage of ndb->extra:s. Fixed with resetting flags at do_after. There is open issue with symmetrical resetting table->file->extra(HA_EXTRA_NO_IGNORE_NO_KEY) which i had to hand to bug#27077. The test for the current bug was committed in a cset for bug#27320.
[29 May 2007 13:36]
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/27573 ChangeSet@1.2472, 2007-05-29 16:36:05+03:00, aelkin@dsl-hkibras1-ff5dc300-70.dhcp.inet.fi +1 -0 Bug#27044 replicated with unique field ndb table allows duplkey inserts The bug in that slave version of a table with unique field still was able to execute INSERT query as replace whereas it's impossible on master. The reason of this artifact is wrong usage of ndb->extra:s. Fixed with resetting flags at do_after. There is open issue with symmetrical resetting table->file->extra(HA_EXTRA_NO_IGNORE_NO_KEY) which i had to hand to bug#27077. The test for the current bug was committed in a cset for bug#27320.
[29 May 2007 14:08]
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/27582 ChangeSet@1.2472, 2007-05-29 15:53:03+03:00, aelkin@dsl-hkibras1-ff5dc300-70.dhcp.inet.fi +1 -0 Bug#27044 replicated with unique field ndb table allows duplkey inserts The bug in that slave version of a table with unique field still was able to execute INSERT query as replace whereas it's impossible on master. The reason of this artifact is wrong usage of ndb->extra:s. Fixed with resetting flags at do_after. There is open issue with symmetrical resetting table->file->extra(HA_EXTRA_NO_IGNORE_NO_KEY) which i had to hand to bug#27077. The test for the current bug was committed in a cset for bug#27320.
[1 Jun 2007 19:21]
Bugs System
Pushed into 5.1.20-beta
[2 Jun 2007 14:35]
Jon Stephens
Thank you for your bug report. This issue has been committed to our source repository of that product and will be incorporated into the next release. If necessary, you can access the source repository and build the latest available version, including the bug fix. More information about accessing the source trees is available at http://dev.mysql.com/doc/en/installing-source.html Documented bugfix in 5.1.20 changelog.