Bug #20751 Assertion in test case ndb_blob
Submitted: 28 Jun 2006 10:07 Modified: 3 Jul 2006 13:11
Reporter: Kristian Nielsen Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Cluster: Cluster (NDB) storage engine Severity:S2 (Serious)
Version:5.1.12 OS:Linux (Linux)
Assigned to: Pekka Nousiainen CPU Architecture:Any

[28 Jun 2006 10:07] Kristian Nielsen
Description:
The test case ndb_blob sometimes causes Assertion and server crash:

mysqld: ha_ndbcluster_binlog.cc:3732: void* ndb_binlog_thread_func(void*): Assertion `(event_types & pOp->getEventType()) != 0' failed.

How to repeat:
The failure does not happen every time, but can be repeated reliably by running the test case in a loop until it fails. It seems to happen more often under Valgrind (but also occurs in normal runs):

(cd mysql-test && for i in `seq 1 100`; do echo XXX $i XXX; MTR_BUILD_THREAD=4 perl mysql-test-run.pl --tmpdir=/dev/shm/t4 --vardir=/dev/shm/v4 --timer --valgrind-all --ps-protocol --mysqld=--binlog-format=row ndb_blob || exit 1; done)
[28 Jun 2006 14:04] Kristian Nielsen
This is the --debug output just before the assert:

T@18262724: | info: EVENT TYPE: 4  GCI: 112  last applied: 110  share: 0xa3a5c50 (test.t1)
T@18262724: | >NdbEventBuffer::getGCIEventOperations
T@18262724: | | info: gci: 112  g.op: 7d2ea58  g.event_types: 2003
T@18262724: | <NdbEventBuffer::getGCIEventOperations

So in

    DBUG_ASSERT((event_types & pOp->getEventType()) != 0);

event_types=0x2003 and pOp->getEventType()=0x4, triggering the assert.
[3 Jul 2006 10:14] 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/8639