Skip to content

Commit d826e36

Browse files
author
Maitrayi Sabaratnam
committed
Bug#32673736 - AUTOTEST: TESTINDEX -N DEFERREDERROR FAILS WITH ARBITRATION ERROR
Lost arbitration ticket problem: The previous test 'testNodeRestart -n Bug18612SR T1' leaves the cluster in a partitioned state with each partition having node-1 as arbitrator, but separately, with different tickets, say node-2 having ticket t1 and node-3 - t2, where t1 committed last, thus t2 is forgotten by the arbitrator. This causes the following 'TESTINDEX -N DEFERREDERROR' execution to fail when it takes node-2 down, due to the new arbitration fails with 'invalid arbitration ticket' error. Fix: Introduce a clean up at the end for the previous test. Reviewed by: Frazer Clement <frazer.clement@oracle.com>
1 parent dcc1692 commit d826e36

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

storage/ndb/test/ndbapi/testNodeRestart.cpp

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
Copyright (c) 2003, 2019, Oracle and/or its affiliates. All rights reserved.
2+
Copyright (c) 2003, 2021, Oracle and/or its affiliates. All rights reserved.
33
44
This program is free software; you can redistribute it and/or modify
55
it under the terms of the GNU General Public License, version 2.0,
@@ -6856,6 +6856,15 @@ runBug18044717(NDBT_Context* ctx, NDBT_Step* step)
68566856
return result;
68576857
}
68586858

6859+
int runRestartAllNodes(NDBT_Context* ctx, NDBT_Step* step)
6860+
{
6861+
NdbRestarter restarter;
6862+
CHECK(restarter.restartAll() == 0, "-");
6863+
CHECK(restarter.waitClusterNoStart() == 0, "-");
6864+
CHECK(restarter.startAll() == 0, "-");
6865+
CHECK(restarter.waitClusterStarted() == 0, "-");
6866+
CHK_NDB_READY(GETNDB(step));
6867+
}
68596868

68606869

68616870
static int createEvent(Ndb *pNdb,
@@ -8312,6 +8321,7 @@ TESTCASE("Bug18612SR",
83128321
"Test bug with partitioned clusters"){
83138322
INITIALIZER(runLoadTable);
83148323
STEP(runBug18612SR);
8324+
FINALIZER(runRestartAllNodes);
83158325
FINALIZER(runClearTable);
83168326
}
83178327
TESTCASE("Bug20185",

0 commit comments

Comments
 (0)