summaryrefslogtreecommitdiff
path: root/ndb
diff options
context:
space:
mode:
authorunknown <gni/root@dev3-221.dev.cn.tlan>2007-02-15 16:52:23 +0800
committerunknown <gni/root@dev3-221.dev.cn.tlan>2007-02-15 16:52:23 +0800
commit35f79a6f5d30bbfa5d7abdd6e5bc096ab2dbaa90 (patch)
tree8d683c01000fb518ef75b88ee025da60c5cdb404 /ndb
parent4fda992bff2034ff551d30cb5da742184ff4a3df (diff)
downloadmariadb-git-35f79a6f5d30bbfa5d7abdd6e5bc096ab2dbaa90.tar.gz
BUG#21715 mgm client command <id> status return version(0.0.0.0)
ndb/src/mgmclient/CommandInterpreter.cpp: Adding the judgement for node type to distinguish the data nodes and non-data nodes. From the return value. Management client can't distinguish the really not connected status for data nodes and status of non-data nodes. We can get the connect status about non-data nodes from version, if the version is 0, it means no connected status.
Diffstat (limited to 'ndb')
-rw-r--r--ndb/src/mgmclient/CommandInterpreter.cpp13
1 files changed, 13 insertions, 0 deletions
diff --git a/ndb/src/mgmclient/CommandInterpreter.cpp b/ndb/src/mgmclient/CommandInterpreter.cpp
index 65d5b038707..e38c1109077 100644
--- a/ndb/src/mgmclient/CommandInterpreter.cpp
+++ b/ndb/src/mgmclient/CommandInterpreter.cpp
@@ -1627,6 +1627,19 @@ CommandInterpreter::executeStatus(int processId,
ndbout << processId << ": Node not found" << endl;
return -1;
}
+ if (cl->node_states[i].node_type != NDB_MGM_NODE_TYPE_NDB){
+ if (cl->node_states[i].version != 0){
+ version = cl->node_states[i].version;
+ ndbout << "Node "<< cl->node_states[i].node_id <<": connected" ;
+ ndbout_c(" (Version %d.%d.%d)",
+ getMajor(version) ,
+ getMinor(version),
+ getBuild(version));
+
+ }else
+ ndbout << "Node "<< cl->node_states[i].node_id <<": not connected" << endl;
+ return 0;
+ }
status = cl->node_states[i].node_status;
startPhase = cl->node_states[i].start_phase;
version = cl->node_states[i].version;