From 6afe69b055f855f969e303102aca4ee3d2bb5f0a Mon Sep 17 00:00:00 2001 From: unknown Date: Thu, 17 Aug 2006 03:52:42 -0400 Subject: [PATCH] BUG#21960: Unbalanced data in MySQL Cluster 5.1 for number of node groups > 1 Fixed bad initialisation of default_node_group, failed to take into account fact that first node group is set to zero storage/ndb/src/kernel/blocks/dbdih/DbdihMain.cpp: Fixed bad initialisation of default_node_group, failed to take into account fact that first node group is set to zero --- storage/ndb/src/kernel/blocks/dbdih/DbdihMain.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/storage/ndb/src/kernel/blocks/dbdih/DbdihMain.cpp b/storage/ndb/src/kernel/blocks/dbdih/DbdihMain.cpp index 0595c018b2e..4d3e0d18688 100644 --- a/storage/ndb/src/kernel/blocks/dbdih/DbdihMain.cpp +++ b/storage/ndb/src/kernel/blocks/dbdih/DbdihMain.cpp @@ -6610,6 +6610,11 @@ void Dbdih::execCREATE_FRAGMENTATION_REQ(Signal * signal) Uint16 next_replica_node[MAX_NDB_NODES]; memset(next_replica_node,0,sizeof(next_replica_node)); Uint32 default_node_group= c_nextNodeGroup; + /** + * Default starts at zero, so we must adjust for this by + * increasing default_node_group already here. + */ + inc_node_or_group(default_node_group, cnoOfNodeGroups); for(Uint32 fragNo = 0; fragNo < noOfFragments; fragNo++) { jam();