summaryrefslogtreecommitdiff
path: root/ndb/test
diff options
context:
space:
mode:
authorunknown <jonas@perch.ndb.mysql.com>2007-02-19 20:13:08 +0100
committerunknown <jonas@perch.ndb.mysql.com>2007-02-19 20:13:08 +0100
commit85fdd106bd4cd9a8e9d9410ceadfad6644d2120d (patch)
tree3a9a4d1c96db5387b52c8977de3980a2879bc198 /ndb/test
parent778b4aad59994e166f91c50b47d686a53a5e8b80 (diff)
downloadmariadb-git-85fdd106bd4cd9a8e9d9410ceadfad6644d2120d.tar.gz
ndb - bug#26481
fix for killed node during initial node restart ndb/src/kernel/blocks/dbdih/Dbdih.hpp: add flag for initial node restart, to keep track on when to concider it to be "done" ndb/src/kernel/blocks/dbdih/DbdihInit.cpp: add flag for initial node restart, to keep track on when to concider it to be "done" ndb/src/kernel/blocks/dbdih/DbdihMain.cpp: add flag for initial node restart, to keep track on when to concider it to be "done" ndb/src/kernel/blocks/dblqh/DblqhMain.cpp: Check cstartRecReq also when refusing GCP_SAVEREQ ndb/test/ndbapi/testNodeRestart.cpp: add testcase
Diffstat (limited to 'ndb/test')
-rw-r--r--ndb/test/ndbapi/testNodeRestart.cpp43
1 files changed, 43 insertions, 0 deletions
diff --git a/ndb/test/ndbapi/testNodeRestart.cpp b/ndb/test/ndbapi/testNodeRestart.cpp
index e729e8179b5..c8c8ddd88d6 100644
--- a/ndb/test/ndbapi/testNodeRestart.cpp
+++ b/ndb/test/ndbapi/testNodeRestart.cpp
@@ -1085,6 +1085,46 @@ retry:
return NDBT_OK;
}
+int
+runBug26481(NDBT_Context* ctx, NDBT_Step* step)
+{
+
+ int result = NDBT_OK;
+ int loops = ctx->getNumLoops();
+ int records = ctx->getNumRecords();
+ NdbRestarter res;
+
+ int node = res.getRandomNotMasterNodeId(rand());
+ ndbout_c("node: %d", node);
+ if (res.restartOneDbNode(node, true, true, true))
+ return NDBT_FAILED;
+
+ if (res.waitNodesNoStart(&node, 1))
+ return NDBT_FAILED;
+
+ int val2[] = { DumpStateOrd::CmvmiSetRestartOnErrorInsert, 1 };
+ if (res.dumpStateOneNode(node, val2, 2))
+ return NDBT_FAILED;
+
+ if (res.insertErrorInNode(node, 7018))
+ return NDBT_FAILED;
+
+ if (res.startNodes(&node, 1))
+ return NDBT_FAILED;
+
+ res.waitNodesStartPhase(&node, 1, 3);
+
+ if (res.waitNodesNoStart(&node, 1))
+ return NDBT_FAILED;
+
+ res.startNodes(&node, 1);
+
+ if (res.waitClusterStarted())
+ return NDBT_FAILED;
+
+ return NDBT_OK;
+}
+
NDBT_TESTSUITE(testNodeRestart);
TESTCASE("NoLoad",
"Test that one node at a time can be stopped and then restarted "\
@@ -1409,6 +1449,9 @@ TESTCASE("Bug25554", ""){
TESTCASE("Bug26457", ""){
INITIALIZER(runBug26457);
}
+TESTCASE("Bug26481", ""){
+ INITIALIZER(runBug26481);
+}
NDBT_TESTSUITE_END(testNodeRestart);
int main(int argc, const char** argv){