Bug #25965 NF causes triggers subsequent ndbassert in DbtupCommit
Submitted: 31 Jan 2007 6:42 Modified: 4 Feb 2008 15:40
Reporter: Tomas Ulin Email Updates:
Status: Duplicate Impact on me:
None 
Category:MySQL Cluster: Cluster (NDB) storage engine Severity:S3 (Non-critical)
Version:5.1.16-ndb OS:Any
Assigned to: Assigned Account CPU Architecture:Any

[31 Jan 2007 6:42] Tomas Ulin
Description:
Found when trying to verify suma bug:

- 2 node cluster, debug compiled
- Node dies on mem alloc assert (as expected)
- but then other node dies right afterwards on:

Error data: dbtup/DbtupCommit.cpp
Error object: DBTUP (Line: 460) 0x0000000a

    fix_commit_order(regOperPtr);
  }
  ndbassert(regOperPtr.p->is_first_operation());
  
  regFragPtr.i= regOperPtr.p->fragmentPtr;

How to repeat:
tried to make testcase smaller but this is as small as it gets for me:

in mysqltest:

modify Suma.cpp in seize_page() to trigger nodefailure:
  if (count == 0)
  {
+     ndbrequire(false);
    return RNIL;
  }

modified ndb/ndbcluster to --small having 2M datamem

ndb/ndbcluster --small --initial
./mysql-test-run.pl --mysqld=--binlog-format=row --mysqld=--ndbcluster --start-and-exit --skip-ndbcluster

mysql> 

create database if not exists TEST_DB;
use TEST_DB;
drop table if exists T1;
create table T1 (KOL1 int unsigned not null,
                 KOL2 int unsigned not null,
	         KOL3 int unsigned not null,
	         KOL4 int unsigned not null,
	         KOL5 int unsigned not null,
	         primary key using hash(KOL1)) engine=ndb;

killall -15 mysqld          (as not to have logging during load)
ndb_mgm -e "all restart"    (to free up gci buffers in suma)

fill up db:

../storage/ndb/test/tools/hugoLoad -b 1 -r 50000 T1
=> out of mem
../storage/ndb/tools/ndb_select_count T1
~21836 records in table T1

start mysqld:
./mysql-test-run.pl --mysqld=--binlog-format=row --mysqld=--ndbcluster --start-and-exit --skip-ndbcluster

mysql> 

create database if not exists TEST_DB;

=====> suma crash
[31 Jan 2007 6:51] Tomas Ulin
trace on ftp:


bug-data-25965.tar.gz

excerpt from ndb_2_trace.log.1:

DBTC    007219 007239 007288 007288 007288 007288 007288 007288 
        007288 007288 007288 007288 007288 007288 007288 007288 
        007288 007288 007288 007288 007288 007288 007288 007288 
        007288 007288 007288 007288 007288 007288 007288 007288 
        007288 007288 007288 007288 007288 007288 007288 007288 
        007288 007288 007288 007288 007288 007288 007288 007288 
        007288 007288 007323 
DBTC    000174 000268 007045 
DBTC    000174 000272 007101 
DBTC    000174 000185 007338 007340 007344 007435 007528 007898 
        007906 007917 
DBTC    000174 000268 007045 
DBTC    000174 000272 007101 
DBLQH   006044 003189 006078 006109 006307 006353 
DBTUP   005450 000460 

--------------- Signal ----------------
r.bn: 247 "DBLQH", r.proc: 2, r.sigId: 227754 gsn: 162 "COMPLETEREQ" prio: 1
s.bn: 245 "DBTC", s.proc: 2, s.sigId: 227751 length: 6 trace: 8 #sec: 0 fragInf: 0
 H'00000000 H'00f50002 H'00000000 H'00500400 H'00f50001 H'000013b2
--------------- Signal ----------------
r.bn: 245 "DBTC", r.proc: 2, r.sigId: 227753 gsn: 164 "CONTINUEB" prio: 1
s.bn: 245 "DBTC", s.proc: 2, s.sigId: 227750 length: 3 trace: 8 #sec: 0 fragInf: 0
 H'00000013 H'00000023 H'00000001
--------------- Signal ----------------
r.bn: 245 "DBTC", r.proc: 2, r.sigId: 227752 gsn: 164 "CONTINUEB" prio: 1
s.bn: 245 "DBTC", s.proc: 2, s.sigId: 227749 length: 3 trace: 8 #sec: 0 fragInf: 0
 H'0000000f H'00000023 H'00000001
--------------- Signal ----------------
r.bn: 245 "DBTC", r.proc: 2, r.sigId: 227751 gsn: 164 "CONTINUEB" prio: 1
s.bn: 245 "DBTC", s.proc: 2, s.sigId: 227748 length: 3 trace: 8 #sec: 0 fragInf: 0
 H'00000002 H'00000000 H'00000000
--------------- Signal ----------------
r.bn: 245 "DBTC", r.proc: 2, r.sigId: 227750 gsn: 164 "CONTINUEB" prio: 1
s.bn: 245 "DBTC", s.proc: 2, s.sigId: 227747 length: 3 trace: 8 #sec: 0 fragInf: 0
 H'00000013 H'00000022 H'00000001
--------------- Signal ----------------
r.bn: 245 "DBTC", r.proc: 2, r.sigId: 227749 gsn: 164 "CONTINUEB" prio: 1
s.bn: 245 "DBTC", s.proc: 2, s.sigId: 227746 length: 3 trace: 8 #sec: 0 fragInf: 0
 H'0000000f H'00000022 H'00000001
--------------- Signal ----------------
r.bn: 245 "DBTC", r.proc: 2, r.sigId: 227748 gsn: 306 "LQH_TRANSCONF" prio: 1
s.bn: 247 "DBLQH", s.proc: 2, s.sigId: 227745 length: 3 trace: 8 #sec: 0 fragInf: 0
 tcRef: 0
 lqhNodeId: 2
 operationStatus: 4
 transId1: 500400
 transId2: f50001
 apiRef: 13b2
 apiOpRec: bf91beb8
 lqhConnectPtr: 40100cf2
 oldTcOpRec: 88547c8
 requestInfo: 837324f
 gci: 0
 nextNodeId1: 40015cc0
 nextNodeId2: bf91bf28
 nextNodeId3: 82ebfb3
 tableId: 88547c8
[31 Jan 2007 22:08] Jonas Oreland
Sorry i've now tried for an hour wo/ being able to reproduce...
[31 Jan 2007 22:14] Jonas Oreland
Shouldnt this be fixed in wl2325-5.0 aswell ?
[4 Feb 2008 15:40] Jonas Oreland
duplicate of 34216