Below is the list of changes that have just been committed into a local
5.1 repository of ndbdev. When ndbdev does a push these changes will
be propagated to the main repository and, within 24 hours after the
push, to the public repository.
For information on how to access the public repository
see http://dev.mysql.com/doc/mysql/en/installing-source-tree.html
ChangeSet@stripped, 2007-06-05 14:22:19+02:00, jmiller@stripped +3 -0
testSystemRestart.cpp, Dbdict.cpp, ERROR_codes.txt:
Updated patch with corrections requested by Tomas for Bug#28770:
storage/ndb/src/kernel/blocks/ERROR_codes.txt@stripped, 2007-06-05 14:21:48+02:00,
jmiller@stripped +2 -1
Updated patch with corrections requested by Tomas for Bug#28770:
storage/ndb/src/kernel/blocks/dbdict/Dbdict.cpp@stripped, 2007-06-05 14:21:37+02:00,
jmiller@stripped +9 -0
Updated patch with corrections requested by Tomas for Bug#28770:
storage/ndb/test/ndbapi/testSystemRestart.cpp@stripped, 2007-06-05 14:22:06+02:00,
jmiller@stripped +49 -0
Updated patch with corrections requested by Tomas for Bug#28770:
# This is a BitKeeper patch. What follows are the unified diffs for the
# set of deltas contained in the patch. The rest of the patch, the part
# that BitKeeper cares about, is below these diffs.
# User: jmiller
# Host: ndb08.mysql.com
# Root: /data1/mysql-5.1-telco4
--- 1.43/storage/ndb/src/kernel/blocks/ERROR_codes.txt 2007-06-05 14:22:31 +02:00
+++ 1.44/storage/ndb/src/kernel/blocks/ERROR_codes.txt 2007-06-05 14:22:31 +02:00
@@ -4,7 +4,7 @@
Next DBACC 3002
Next DBTUP 4029
Next DBLQH 5047
-Next DBDICT 6007
+Next DBDICT 6008
Next DBDIH 7183
Next DBTC 8040
Next CMVMI 9000
@@ -503,6 +503,7 @@
6003 Crash in participant @ CreateTabReq::Prepare
6004 Crash in participant @ CreateTabReq::Commit
6005 Crash in participant @ CreateTabReq::CreateDrop
+6007 Fail on readTableFile for READ_TAB_FILE1 (28770)
Dbtup:
4014 - handleInsert - Out of undo buffer
--- 1.138/storage/ndb/src/kernel/blocks/dbdict/Dbdict.cpp 2007-06-05 14:22:31 +02:00
+++ 1.139/storage/ndb/src/kernel/blocks/dbdict/Dbdict.cpp 2007-06-05 14:22:31 +02:00
@@ -804,6 +804,15 @@
readSchemaConf(signal ,fsPtr);
break;
case FsConnectRecord::READ_TAB_FILE1:
+ if(ERROR_INSERTED(6007)){
+ jam();
+ FsRef * const fsRef = (FsRef *)&signal->theData[0];
+ fsRef->userPointer = fsConf->userPointer;
+ fsRef->setErrorCode(fsRef->errorCode, NDBD_EXIT_AFS_UNKNOWN);
+ fsRef->osErrorCode = ~0; // Indicate local error
+ execFSREADREF(signal);
+ return;
+ }//Testing how DICT behave if read of file 1 fails (Bug#28770)
case FsConnectRecord::READ_TAB_FILE2:
jam();
readTableConf(signal ,fsPtr);
--- 1.14/storage/ndb/test/ndbapi/testSystemRestart.cpp 2007-06-05 14:22:31 +02:00
+++ 1.15/storage/ndb/test/ndbapi/testSystemRestart.cpp 2007-06-05 14:22:31 +02:00
@@ -1267,6 +1267,42 @@
return result;
}
+int
+runBug28770(NDBT_Context* ctx, NDBT_Step* step) {
+ Ndb* pNdb = GETNDB(step);
+ NdbRestarter restarter;
+ int result = NDBT_OK;
+ int count = 0;
+ Uint32 i = 0;
+ Uint32 loops = ctx->getNumLoops();
+ int records = ctx->getNumRecords();
+ UtilTransactions utilTrans(*ctx->getTab());
+ HugoTransactions hugoTrans(*ctx->getTab());
+
+ g_info << "Loading records..." << endl;
+ hugoTrans.loadTable(pNdb, records);
+
+
+ while(i<=loops && result != NDBT_FAILED){
+ g_info << "Loop " << i << "/"<< loops <<" started"
<< endl;
+ CHECK(restarter.restartAll(false, true, false) == 0);
+ NdbSleep_SecSleep(3);
+ CHECK(restarter.waitClusterNoStart() == 0);
+ restarter.insertErrorInAllNodes(6007);
+ CHECK(restarter.startAll()== 0);
+ CHECK(restarter.waitClusterStarted() == 0);
+ CHECK(utilTrans.selectCount(pNdb, 64, &count) == 0);
+ CHECK(count == records);
+ i++;
+ }
+
+
+ ndbout << " runBug28770 finished" << endl;
+
+ return result;
+}
+
+
NDBT_TESTSUITE(testSystemRestart);
TESTCASE("SR1",
"Basic system restart test. Focus on testing restart from REDO log.\n"
@@ -1452,6 +1488,19 @@
{
INITIALIZER(runWaitStarted);
STEP(runBug27434);
+}
+TESTCASE("Bug28770",
+ "Check readTableFile1 fails, readTableFile2 succeeds\n"
+ "1. Restart all node -nostart\n"
+ "2. Insert error 6100 into all nodes\n"
+ "3. Start all nodes\n"
+ "4. Ensure cluster start\n"
+ "5. Read and verify reocrds\n"
+ "6. Repeat until looping is completed\n"){
+ INITIALIZER(runWaitStarted);
+ INITIALIZER(runClearTable);
+ STEP(runBug28770);
+ FINALIZER(runClearTable);
}
NDBT_TESTSUITE_END(testSystemRestart);
| Thread |
|---|
| • bk commit into 5.1 tree (jmiller:1.2515) BUG#28770 | Jonathan Miller | 5 Jun |