You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@iotdb.apache.org by GitBox <gi...@apache.org> on 2020/09/03 03:33:51 UTC

[GitHub] [incubator-iotdb] LebronAl commented on a change in pull request #1667: [IOTDB-859] list all files generated or used by IoTDB

LebronAl commented on a change in pull request #1667:
URL: https://github.com/apache/incubator-iotdb/pull/1667#discussion_r482676859



##########
File path: docs/UserGuide/System Tools/NodeTool.md
##########
@@ -0,0 +1,288 @@
+<!--
+
+    Licensed to the Apache Software Foundation (ASF) under one
+    or more contributor license agreements.  See the NOTICE file
+    distributed with this work for additional information
+    regarding copyright ownership.  The ASF licenses this file
+    to you under the Apache License, Version 2.0 (the
+    "License"); you may not use this file except in compliance
+    with the License.  You may obtain a copy of the License at
+
+        http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing,
+    software distributed under the License is distributed on an
+    "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+    KIND, either express or implied.  See the License for the
+    specific language governing permissions and limitations
+    under the License.
+
+-->
+
+# Introduction
+IoTDB cluster version provides nodetool shell tool for users to monitor the working status of the specified cluster. 
+Users can obtain the status of the cluster by running a variety of instructions.
+
+The following describes the usage and examples of each instruction, 
+where $IOTDB_CLUSTER_ Home indicates the path of the IoTDB Distributed installation directory.

Review comment:
       It seems to be $IOTDB_CLUSTER_HOME~

##########
File path: docs/UserGuide/System Tools/NodeTool.md
##########
@@ -0,0 +1,288 @@
+<!--
+
+    Licensed to the Apache Software Foundation (ASF) under one
+    or more contributor license agreements.  See the NOTICE file
+    distributed with this work for additional information
+    regarding copyright ownership.  The ASF licenses this file
+    to you under the Apache License, Version 2.0 (the
+    "License"); you may not use this file except in compliance
+    with the License.  You may obtain a copy of the License at
+
+        http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing,
+    software distributed under the License is distributed on an
+    "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+    KIND, either express or implied.  See the License for the
+    specific language governing permissions and limitations
+    under the License.
+
+-->
+
+# Introduction
+IoTDB cluster version provides nodetool shell tool for users to monitor the working status of the specified cluster. 
+Users can obtain the status of the cluster by running a variety of instructions.
+
+The following describes the usage and examples of each instruction, 
+where $IOTDB_CLUSTER_ Home indicates the path of the IoTDB Distributed installation directory.
+# Instructions
+## Get Started
+The nodetool shell tool startup script is located at $IOTDB_CLUSTER_HOME/bin folder, 
+you can specify the IP address and port of the cluster at startup.
+
+IP is the IP of the node that the user expects to connect to,
+and port is the JMX service port specified when the IoTDB cluster is started.
+
+The default values are 127.0.0.1 and 31999, respectively.
+
+If you need to monitor the remote cluster or modify the JMX service port number,
+use the actual IP and port at the -H and -P entries.
+
+## Explains
+In a distributed system, a node is identified by node IP, metadata port and data port \<METAPORT:DATAPORT>.
+### Show The Ring Of Node
+IoTDB cluster version uses consistent hash to achieve data distribution.
+
+Users can know the location of each node in the ring by printing hash ring information.
+
+1.Input
+> ring
+
+2.Output
+
+> The output is a multi line string, and each line of string is a key value pair, 
+> where the key represents the token value and the value represents the node (IP:METAPORT:DATAPORT), the format is \<key -> value>.
+
+3.Examples
+
+> Suppose that the current cluster runs on three nodes: 127.0.0.1:9003:40010, 127.0.0.1:9005:40012 and 127.0.0.1:9004:40011.
+> 
+> Examples of input instructions for different systems are as follows:
+
+Linux and MacOS:
+
+```
+Shell > ./bin/nodetool.sh -h 127.0.0.1 -p 31999 ring
+```
+
+Windows:
+
+```
+Shell > \bin\nodetool.bat -h 127.0.0.1 -p 31999 ring
+```
+
+Press enter to execute the command. 
+
+The output of the example instruction is as follows:
+```
+Node Identifier                                 Node 
+330411070           ->          127.0.0.1:9003:40010 
+330454032           ->          127.0.0.1:9004:40011 
+330496472           ->          127.0.0.1:9005:40012
+```
+ 
+The above output shows that there are three nodes in the current cluster,
+and the output results are output clockwise according to their positions in the ring.
+
+### Query data partition and metadata partition
+The time series metadata of iotdb cluster version is divided into multiple data partitions according to storage groups,
+in which the storage group and data partition are many to one relationship.
+
+That is, the same storage group only exists in the same data partition,
+and a data partition contains multiple storage groups.
+
+The data is divided into multiple data partitions according to the storage group and time interval,
+and the partition granularity is <storage group, time range>.
+
+The data partition is composed of replica nodes,
+and one of the nodes plays the role of leader.
+
+Through this instruction, the user can know the metadata under a certain path
+ or the nodes under which the data is stored.
+
+1.Input
+> The instruction for querying data partition information is partition.
+> The parameters are described as follows:
+
+|Parameter|Description|Examples|
+| --- | --- | --- |
+|-m | --metadata	Query metadata partition, the default is query data partition|	-m |
+|-path | --path 	Required parameter, the path to be queried. If the path has no corresponding storage group, the query fails|	-path root.guangzhou.d1|
+|-st | --StartTime	The system uses the current partition time by default|	-st 1576724778159 |
+|-et | --EndTime	It is used when querying data partition.<br>The end time is the current system time by default. <br> If the end time is less than the start time, the end time is the start time by default|-et 1576724778159 |
+
+2.Output
+
+> The output is a multi line string, and each line of string is a key value pair, where the key represents the partition,
+> and the value represents the data group in the format of \< key -> value>.
+
+3.Examples
+
+> Suppose that the current cluster runs on three nodes: 127.0.0.1:9003:40010, 127.0.0.1:9005:40012 and 127.0.0.1:9004:40011.

Review comment:
       These three nodes are best aligned with the clockwise order of the nodes

##########
File path: docs/UserGuide/System Tools/NodeTool.md
##########
@@ -0,0 +1,288 @@
+<!--
+
+    Licensed to the Apache Software Foundation (ASF) under one
+    or more contributor license agreements.  See the NOTICE file
+    distributed with this work for additional information
+    regarding copyright ownership.  The ASF licenses this file
+    to you under the Apache License, Version 2.0 (the
+    "License"); you may not use this file except in compliance
+    with the License.  You may obtain a copy of the License at
+
+        http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing,
+    software distributed under the License is distributed on an
+    "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+    KIND, either express or implied.  See the License for the
+    specific language governing permissions and limitations
+    under the License.
+
+-->
+
+# Introduction
+IoTDB cluster version provides nodetool shell tool for users to monitor the working status of the specified cluster. 
+Users can obtain the status of the cluster by running a variety of instructions.
+
+The following describes the usage and examples of each instruction, 
+where $IOTDB_CLUSTER_ Home indicates the path of the IoTDB Distributed installation directory.
+# Instructions
+## Get Started
+The nodetool shell tool startup script is located at $IOTDB_CLUSTER_HOME/bin folder, 
+you can specify the IP address and port of the cluster at startup.
+
+IP is the IP of the node that the user expects to connect to,
+and port is the JMX service port specified when the IoTDB cluster is started.
+
+The default values are 127.0.0.1 and 31999, respectively.
+
+If you need to monitor the remote cluster or modify the JMX service port number,
+use the actual IP and port at the -H and -P entries.
+
+## Explains
+In a distributed system, a node is identified by node IP, metadata port and data port \<METAPORT:DATAPORT>.
+### Show The Ring Of Node
+IoTDB cluster version uses consistent hash to achieve data distribution.
+
+Users can know the location of each node in the ring by printing hash ring information.
+
+1.Input
+> ring
+
+2.Output
+
+> The output is a multi line string, and each line of string is a key value pair, 
+> where the key represents the token value and the value represents the node (IP:METAPORT:DATAPORT), the format is \<key -> value>.
+
+3.Examples
+
+> Suppose that the current cluster runs on three nodes: 127.0.0.1:9003:40010, 127.0.0.1:9005:40012 and 127.0.0.1:9004:40011.
+> 
+> Examples of input instructions for different systems are as follows:
+
+Linux and MacOS:
+
+```
+Shell > ./bin/nodetool.sh -h 127.0.0.1 -p 31999 ring
+```
+
+Windows:
+
+```
+Shell > \bin\nodetool.bat -h 127.0.0.1 -p 31999 ring
+```
+
+Press enter to execute the command. 
+
+The output of the example instruction is as follows:
+```
+Node Identifier                                 Node 
+330411070           ->          127.0.0.1:9003:40010 
+330454032           ->          127.0.0.1:9004:40011 
+330496472           ->          127.0.0.1:9005:40012
+```
+ 
+The above output shows that there are three nodes in the current cluster,
+and the output results are output clockwise according to their positions in the ring.
+
+### Query data partition and metadata partition
+The time series metadata of iotdb cluster version is divided into multiple data partitions according to storage groups,
+in which the storage group and data partition are many to one relationship.
+
+That is, the same storage group only exists in the same data partition,
+and a data partition contains multiple storage groups.
+
+The data is divided into multiple data partitions according to the storage group and time interval,
+and the partition granularity is <storage group, time range>.
+
+The data partition is composed of replica nodes,

Review comment:
       I think it's best to state here that a time partition consists of a raft group, thus ensuring high availability of data.

##########
File path: docs/zh/UserGuide/System Tools/NodeTool.md
##########
@@ -0,0 +1,245 @@
+<!--
+
+    Licensed to the Apache Software Foundation (ASF) under one
+    or more contributor license agreements.  See the NOTICE file
+    distributed with this work for additional information
+    regarding copyright ownership.  The ASF licenses this file
+    to you under the Apache License, Version 2.0 (the
+    "License"); you may not use this file except in compliance
+    with the License.  You may obtain a copy of the License at
+
+        http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing,
+    software distributed under the License is distributed on an
+    "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+    KIND, either express or implied.  See the License for the
+    specific language governing permissions and limitations
+    under the License.
+
+-->
+
+# 工具介绍
+IoTDB集群版为用户提供了NodeTool Shell工具用于监控指定集群的工作状态,用户可以通过运行多种指令获取集群各项状态。
+
+下面具体介绍每个指令的使用方式及示例,其中$IOTDB_CLUSTER_HOME表示IoTDB分布式的安装目录所在路径。
+# 使用说明
+## 运行方式
+NodeTool Shell工具启动脚本位于$IOTDB_CLUSTER_HOME/bin文件夹下,启动时可以指定集群运行的IP和PORT。
+
+其中IP为用户期望连接的节点的IP,PORT为IoTDB集群启动时指定的JMX服务端口号,分别默认为127.0.0.1和31999。
+
+如果用户需要监控远程集群或修改了JMX服务端口号,请在-h和-p项处使用实际的IP和PORT。
+
+## 指令说明
+在分布式系统中,一个节点由节点IP,元数据端口和数据端口来标识,即Node\<IP:METAPORT:DATAPORT>。
+### 展示节点环
+IoTDB集群版采用一致性哈希的方式实现数据分布,用户可以通过打印哈希环信息了解每个节点在环中的位置。
+
+1.输入
+> 打印哈希环的指令为ring
+
+2.输出
+
+> 输出为多行字符串,每行字符串为一个键值对,其中键表示令牌值,值表示节点(IP:METAPORT:DATAPORT),格式为\<key -> value>。
+
+3.示例
+
+> 假设当前集群运行在127.0.0.1:9003:40010、127.0.0.1:9005:40012和127.0.0.1:9004:40011三个节点上。
+不同系统的输入指令示例如下:
+
+Linux系统与MacOS系统:
+
+```
+Shell > ./bin/nodetool.sh -h 127.0.0.1 -p 31999 ring
+```
+
+Windows系统:
+
+```
+Shell > \bin\nodetool.bat -h 127.0.0.1 -p 31999 ring
+```
+ 
+回车后即可执行指令。示例指令的输出如下:
+```
+Node Identifier                                 Node 
+330411070           ->          127.0.0.1:9003:40010 
+330454032           ->          127.0.0.1:9004:40011 
+330496472           ->          127.0.0.1:9005:40012
+```
+ 
+上述输出表示当前集群共有3个节点,按照在环中的位置顺时针输出结果。
+
+### 查询数据分区和元数据分区
+IoTDB集群版的时间序列元数据按照存储组分为多个数据分区,其中存储组和数据分区为多对一的关系,
+即同一个存储组只存在于同一个数据分区,一个数据分区包含多个存储组;
+
+数据按照存储组和时间区间分为多个数据分区,分区粒度为<Storage Group,Time Range>。
+
+数据分区由多个节点组成,节点数量为副本数,其中某一个节点担任Leader的角色。

Review comment:
       same as above

##########
File path: docs/UserGuide/System Tools/NodeTool.md
##########
@@ -0,0 +1,288 @@
+<!--
+
+    Licensed to the Apache Software Foundation (ASF) under one
+    or more contributor license agreements.  See the NOTICE file
+    distributed with this work for additional information
+    regarding copyright ownership.  The ASF licenses this file
+    to you under the Apache License, Version 2.0 (the
+    "License"); you may not use this file except in compliance
+    with the License.  You may obtain a copy of the License at
+
+        http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing,
+    software distributed under the License is distributed on an
+    "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+    KIND, either express or implied.  See the License for the
+    specific language governing permissions and limitations
+    under the License.
+
+-->
+
+# Introduction
+IoTDB cluster version provides nodetool shell tool for users to monitor the working status of the specified cluster. 
+Users can obtain the status of the cluster by running a variety of instructions.
+
+The following describes the usage and examples of each instruction, 
+where $IOTDB_CLUSTER_ Home indicates the path of the IoTDB Distributed installation directory.
+# Instructions
+## Get Started
+The nodetool shell tool startup script is located at $IOTDB_CLUSTER_HOME/bin folder, 
+you can specify the IP address and port of the cluster at startup.
+
+IP is the IP of the node that the user expects to connect to,
+and port is the JMX service port specified when the IoTDB cluster is started.
+
+The default values are 127.0.0.1 and 31999, respectively.
+
+If you need to monitor the remote cluster or modify the JMX service port number,
+use the actual IP and port at the -H and -P entries.
+
+## Explains
+In a distributed system, a node is identified by node IP, metadata port and data port \<METAPORT:DATAPORT>.
+### Show The Ring Of Node
+IoTDB cluster version uses consistent hash to achieve data distribution.
+
+Users can know the location of each node in the ring by printing hash ring information.
+
+1.Input
+> ring
+
+2.Output
+
+> The output is a multi line string, and each line of string is a key value pair, 
+> where the key represents the token value and the value represents the node (IP:METAPORT:DATAPORT), the format is \<key -> value>.
+
+3.Examples
+
+> Suppose that the current cluster runs on three nodes: 127.0.0.1:9003:40010, 127.0.0.1:9005:40012 and 127.0.0.1:9004:40011.

Review comment:
       These three nodes are best aligned with the clockwise order of the nodes

##########
File path: docs/zh/UserGuide/System Tools/NodeTool.md
##########
@@ -0,0 +1,245 @@
+<!--
+
+    Licensed to the Apache Software Foundation (ASF) under one
+    or more contributor license agreements.  See the NOTICE file
+    distributed with this work for additional information
+    regarding copyright ownership.  The ASF licenses this file
+    to you under the Apache License, Version 2.0 (the
+    "License"); you may not use this file except in compliance
+    with the License.  You may obtain a copy of the License at
+
+        http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing,
+    software distributed under the License is distributed on an
+    "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+    KIND, either express or implied.  See the License for the
+    specific language governing permissions and limitations
+    under the License.
+
+-->
+
+# 工具介绍
+IoTDB集群版为用户提供了NodeTool Shell工具用于监控指定集群的工作状态,用户可以通过运行多种指令获取集群各项状态。
+
+下面具体介绍每个指令的使用方式及示例,其中$IOTDB_CLUSTER_HOME表示IoTDB分布式的安装目录所在路径。
+# 使用说明
+## 运行方式
+NodeTool Shell工具启动脚本位于$IOTDB_CLUSTER_HOME/bin文件夹下,启动时可以指定集群运行的IP和PORT。
+
+其中IP为用户期望连接的节点的IP,PORT为IoTDB集群启动时指定的JMX服务端口号,分别默认为127.0.0.1和31999。
+
+如果用户需要监控远程集群或修改了JMX服务端口号,请在-h和-p项处使用实际的IP和PORT。
+
+## 指令说明
+在分布式系统中,一个节点由节点IP,元数据端口和数据端口来标识,即Node\<IP:METAPORT:DATAPORT>。
+### 展示节点环
+IoTDB集群版采用一致性哈希的方式实现数据分布,用户可以通过打印哈希环信息了解每个节点在环中的位置。
+
+1.输入
+> 打印哈希环的指令为ring
+
+2.输出
+
+> 输出为多行字符串,每行字符串为一个键值对,其中键表示令牌值,值表示节点(IP:METAPORT:DATAPORT),格式为\<key -> value>。
+
+3.示例
+
+> 假设当前集群运行在127.0.0.1:9003:40010、127.0.0.1:9005:40012和127.0.0.1:9004:40011三个节点上。

Review comment:
       same as above

##########
File path: docs/UserGuide/System Tools/NodeTool.md
##########
@@ -0,0 +1,288 @@
+<!--
+
+    Licensed to the Apache Software Foundation (ASF) under one
+    or more contributor license agreements.  See the NOTICE file
+    distributed with this work for additional information
+    regarding copyright ownership.  The ASF licenses this file
+    to you under the Apache License, Version 2.0 (the
+    "License"); you may not use this file except in compliance
+    with the License.  You may obtain a copy of the License at
+
+        http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing,
+    software distributed under the License is distributed on an
+    "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+    KIND, either express or implied.  See the License for the
+    specific language governing permissions and limitations
+    under the License.
+
+-->
+
+# Introduction
+IoTDB cluster version provides nodetool shell tool for users to monitor the working status of the specified cluster. 
+Users can obtain the status of the cluster by running a variety of instructions.
+
+The following describes the usage and examples of each instruction, 
+where $IOTDB_CLUSTER_ Home indicates the path of the IoTDB Distributed installation directory.
+# Instructions
+## Get Started
+The nodetool shell tool startup script is located at $IOTDB_CLUSTER_HOME/bin folder, 
+you can specify the IP address and port of the cluster at startup.
+
+IP is the IP of the node that the user expects to connect to,
+and port is the JMX service port specified when the IoTDB cluster is started.
+
+The default values are 127.0.0.1 and 31999, respectively.
+
+If you need to monitor the remote cluster or modify the JMX service port number,
+use the actual IP and port at the -H and -P entries.
+
+## Explains
+In a distributed system, a node is identified by node IP, metadata port and data port \<METAPORT:DATAPORT>.
+### Show The Ring Of Node
+IoTDB cluster version uses consistent hash to achieve data distribution.
+
+Users can know the location of each node in the ring by printing hash ring information.
+
+1.Input
+> ring
+
+2.Output
+
+> The output is a multi line string, and each line of string is a key value pair, 
+> where the key represents the token value and the value represents the node (IP:METAPORT:DATAPORT), the format is \<key -> value>.
+
+3.Examples
+
+> Suppose that the current cluster runs on three nodes: 127.0.0.1:9003:40010, 127.0.0.1:9005:40012 and 127.0.0.1:9004:40011.
+> 
+> Examples of input instructions for different systems are as follows:
+
+Linux and MacOS:
+
+```
+Shell > ./bin/nodetool.sh -h 127.0.0.1 -p 31999 ring
+```
+
+Windows:
+
+```
+Shell > \bin\nodetool.bat -h 127.0.0.1 -p 31999 ring
+```
+
+Press enter to execute the command. 
+
+The output of the example instruction is as follows:
+```
+Node Identifier                                 Node 
+330411070           ->          127.0.0.1:9003:40010 
+330454032           ->          127.0.0.1:9004:40011 
+330496472           ->          127.0.0.1:9005:40012
+```
+ 
+The above output shows that there are three nodes in the current cluster,
+and the output results are output clockwise according to their positions in the ring.
+
+### Query data partition and metadata partition
+The time series metadata of iotdb cluster version is divided into multiple data partitions according to storage groups,
+in which the storage group and data partition are many to one relationship.
+
+That is, the same storage group only exists in the same data partition,
+and a data partition contains multiple storage groups.
+
+The data is divided into multiple data partitions according to the storage group and time interval,
+and the partition granularity is <storage group, time range>.
+
+The data partition is composed of replica nodes,
+and one of the nodes plays the role of leader.
+
+Through this instruction, the user can know the metadata under a certain path
+ or the nodes under which the data is stored.
+
+1.Input
+> The instruction for querying data partition information is partition.
+> The parameters are described as follows:
+
+|Parameter|Description|Examples|
+| --- | --- | --- |
+|-m | --metadata	Query metadata partition, the default is query data partition|	-m |
+|-path | --path 	Required parameter, the path to be queried. If the path has no corresponding storage group, the query fails|	-path root.guangzhou.d1|
+|-st | --StartTime	The system uses the current partition time by default|	-st 1576724778159 |
+|-et | --EndTime	It is used when querying data partition.<br>The end time is the current system time by default. <br> If the end time is less than the start time, the end time is the start time by default|-et 1576724778159 |
+
+2.Output
+
+> The output is a multi line string, and each line of string is a key value pair, where the key represents the partition,
+> and the value represents the data group in the format of \< key -> value>.
+
+3.Examples
+
+> Suppose that the current cluster runs on three nodes: 127.0.0.1:9003:40010, 127.0.0.1:9005:40012 and 127.0.0.1:9004:40011.
+> 
+> The number of copies is 2 and there are 3 storage groups:{ root.beijing , root.shanghai , root.guangzhou}.
+
++ Partition of query data (default time interval, time dimension is partitioned by day)
+
+Linux and MacOS:
+```
+Shell > ./bin/nodetool.sh -h 127.0.0.1 -p 31999 partition -path root.guangzhou.d1
+```
+Windows:
+```
+Shell > \bin\nodetool.bat -h 127.0.0.1 -p 31999 partition -path root.guangzhou.d1
+```
+
+Press enter to execute the command. 
+
+The output of the example instruction is as follows:
+```
+DATA<root.guangzhou.d1, 1576723735188, 1576723735188>	->	[127.0.0.1:9003:40010, 127.0.0.1:9004:40011]
+```
+
++ Partition of query data (specified time interval, time dimension is partitioned by day)
+
+
+Linux and MacOS:
+```
+Shell > ./bin/nodetool.sh -h 127.0.0.1 -p 31999 partition -path root.guangzhou.d1 -st 1576624778159 -et 1576724778159
+```
+Windows:
+```
+Shell > \bin\nodetool.bat -h 127.0.0.1 -p 31999 partition -path root.guangzhou.d1 -st 1576624778159 -et 1576724778159
+```
+
+Press enter to execute the command. 
+
+The output of the example instruction is as follows:
+```
+DATA<root.guangzhou.d1, 1576627200000, 1576713599999>	->	[127.0.0.1:9005:40012, 127.0.0.1:9003:40010] 
+DATA<root.guangzhou.d1, 1576713600000, 1576724778159>	->	[127.0.0.1:9003:40010, 127.0.0.1:9004:40011] 
+DATA<root.guangzhou.d1, 1576624778159, 1576627199999>	->	[127.0.0.1:9004:40011, 127.0.0.1:9005:40012]
+```
+
++ Query metadata partition
+
+Linux and MacOS:
+```
+Shell > ./bin/nodetool.sh -h 127.0.0.1 -p 31999 partition -path root.guangzhou.d1 -m
+```
+Windows:
+```
+Shell > \bin\nodetool.bat -h 127.0.0.1 -p 31999 partition -path root.guangzhou.d1 -m
+```
+
+Press enter to execute the command. 
+
+The output of the example instruction is as follows:
+```
+DATA<root.guangzhou.d1, 1576723735188, 1576723735188>	->	[127.0.0.1:9003:40010, 127.0.0.1:9004:40011]
+```
+The above output shows that the data partition to which root.t1.d1 belongs contains two nodes,
+of which 127.0.0.1:9003:40010 is the leader node.

Review comment:
       is this first node a leader node or header node?

##########
File path: docs/zh/UserGuide/System Tools/NodeTool.md
##########
@@ -0,0 +1,245 @@
+<!--
+
+    Licensed to the Apache Software Foundation (ASF) under one
+    or more contributor license agreements.  See the NOTICE file
+    distributed with this work for additional information
+    regarding copyright ownership.  The ASF licenses this file
+    to you under the Apache License, Version 2.0 (the
+    "License"); you may not use this file except in compliance
+    with the License.  You may obtain a copy of the License at
+
+        http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing,
+    software distributed under the License is distributed on an
+    "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+    KIND, either express or implied.  See the License for the
+    specific language governing permissions and limitations
+    under the License.
+
+-->
+
+# 工具介绍
+IoTDB集群版为用户提供了NodeTool Shell工具用于监控指定集群的工作状态,用户可以通过运行多种指令获取集群各项状态。
+
+下面具体介绍每个指令的使用方式及示例,其中$IOTDB_CLUSTER_HOME表示IoTDB分布式的安装目录所在路径。
+# 使用说明
+## 运行方式
+NodeTool Shell工具启动脚本位于$IOTDB_CLUSTER_HOME/bin文件夹下,启动时可以指定集群运行的IP和PORT。
+
+其中IP为用户期望连接的节点的IP,PORT为IoTDB集群启动时指定的JMX服务端口号,分别默认为127.0.0.1和31999。
+
+如果用户需要监控远程集群或修改了JMX服务端口号,请在-h和-p项处使用实际的IP和PORT。
+
+## 指令说明
+在分布式系统中,一个节点由节点IP,元数据端口和数据端口来标识,即Node\<IP:METAPORT:DATAPORT>。
+### 展示节点环
+IoTDB集群版采用一致性哈希的方式实现数据分布,用户可以通过打印哈希环信息了解每个节点在环中的位置。
+
+1.输入
+> 打印哈希环的指令为ring
+
+2.输出
+
+> 输出为多行字符串,每行字符串为一个键值对,其中键表示令牌值,值表示节点(IP:METAPORT:DATAPORT),格式为\<key -> value>。
+
+3.示例
+
+> 假设当前集群运行在127.0.0.1:9003:40010、127.0.0.1:9005:40012和127.0.0.1:9004:40011三个节点上。
+不同系统的输入指令示例如下:
+
+Linux系统与MacOS系统:
+
+```
+Shell > ./bin/nodetool.sh -h 127.0.0.1 -p 31999 ring
+```
+
+Windows系统:
+
+```
+Shell > \bin\nodetool.bat -h 127.0.0.1 -p 31999 ring
+```
+ 
+回车后即可执行指令。示例指令的输出如下:
+```
+Node Identifier                                 Node 
+330411070           ->          127.0.0.1:9003:40010 
+330454032           ->          127.0.0.1:9004:40011 
+330496472           ->          127.0.0.1:9005:40012
+```
+ 
+上述输出表示当前集群共有3个节点,按照在环中的位置顺时针输出结果。
+
+### 查询数据分区和元数据分区
+IoTDB集群版的时间序列元数据按照存储组分为多个数据分区,其中存储组和数据分区为多对一的关系,
+即同一个存储组只存在于同一个数据分区,一个数据分区包含多个存储组;
+
+数据按照存储组和时间区间分为多个数据分区,分区粒度为<Storage Group,Time Range>。
+
+数据分区由多个节点组成,节点数量为副本数,其中某一个节点担任Leader的角色。
+
+通过该指令,用户可以获知某个路径下的元数据或数据具体存储在哪些节点下。
+
+1.输入
+> 查询数据分区信息的指令为partition,参数具体说明如下:
+
+|参数名|参数说明|示例|
+| --- | --- | --- |
+|-m | --metadata	查询元数据分区,默认为查询数据分区|	-m |
+|-path | --path 	必要参数,需要查询的路径,若该路径无对应的存储组,则查询失败|	-path root.guangzhou.d1|
+|-st | --StartTime	查询数据分区时使用,起始时间,默认为系统当前时间|	-st 1576724778159 |
+|-et | --EndTime	查询数据分区时使用,终止时间,默认为系统当前时间。若终止时间小于起始时间,则终止时间默认为起始时间|	-et 1576724778159 |
+
+2.输出
+
+> 输出为多行字符串,每行字符串为一个键值对,其中键表示分区,值表示数据组,格式为\<key -> value>。
+
+3.示例
+
+> 假设当前集群运行在127.0.0.1:9003:40010、127.0.0.1:9005:40012和127.0.0.1:9004:40011三个节点上,
+副本数为2,共有3个存储组:{root.beijing、root.shanghai、root.guangzhou}。
+
++ 查询数据的分区(默认时间区间, 时间维度按天分区)
+
+不同系统的输入指令示例如下:
+
+Linux系统与MacOS系统:
+```
+Shell > ./bin/nodetool.sh -h 127.0.0.1 -p 31999 partition -path root.guangzhou.d1
+```
+Windows系统:
+```
+Shell > \bin\nodetool.bat -h 127.0.0.1 -p 31999 partition -path root.guangzhou.d1
+```
+回车后即可执行指令。示例指令的输出如下:
+```
+DATA<root.guangzhou.d1, 1576723735188, 1576723735188>	->	[127.0.0.1:9003:40010, 127.0.0.1:9004:40011]
+```
+
++ 查询数据的分区(指定时间区间, 时间维度按天分区)
+
+不同系统的输入指令示例如下:
+
+Linux系统与MacOS系统:
+```
+Shell > ./bin/nodetool.sh -h 127.0.0.1 -p 31999 partition -path root.guangzhou.d1 -st 1576624778159 -et 1576724778159
+```
+Windows系统:
+```
+Shell > \bin\nodetool.bat -h 127.0.0.1 -p 31999 partition -path root.guangzhou.d1 -st 1576624778159 -et 1576724778159
+```
+回车后即可执行指令。示例指令的输出如下:
+```
+DATA<root.guangzhou.d1, 1576627200000, 1576713599999>	->	[127.0.0.1:9005:40012, 127.0.0.1:9003:40010] 
+DATA<root.guangzhou.d1, 1576713600000, 1576724778159>	->	[127.0.0.1:9003:40010, 127.0.0.1:9004:40011] 
+DATA<root.guangzhou.d1, 1576624778159, 1576627199999>	->	[127.0.0.1:9004:40011, 127.0.0.1:9005:40012]
+```
+
++ 查询元数据分区
+
+不同系统的输入指令示例如下:
+
+Linux系统与MacOS系统:
+```
+Shell > ./bin/nodetool.sh -h 127.0.0.1 -p 31999 partition -path root.guangzhou.d1 -m
+```
+Windows系统:
+```
+Shell > \bin\nodetool.bat -h 127.0.0.1 -p 31999 partition -path root.guangzhou.d1 -m
+```
+回车后即可执行指令。示例指令的输出如下:
+```
+DATA<root.guangzhou.d1, 1576723735188, 1576723735188>	->	[127.0.0.1:9003:40010, 127.0.0.1:9004:40011]
+```
+上述输出表示root.t1.d1所属的数据分区包含2个节点,其中127.0.0.1:9003:40010为leader节点。

Review comment:
       same as above




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org