You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@iotdb.apache.org by qi...@apache.org on 2019/11/16 11:43:29 UTC

[incubator-iotdb] branch rel/0.9 updated (2d603fb -> c560e76)

This is an automated email from the ASF dual-hosted git repository.

qiaojialin pushed a change to branch rel/0.9
in repository https://gitbox.apache.org/repos/asf/incubator-iotdb.git.


    from 2d603fb  [maven-release-plugin] prepare for next development iteration
     new 4c1205c  Correct python example (#561)
     new 780d250  update readme (#556)
     new b0ccc31  Fix start script (#533)
     new 143badd  [IOTDB-300]reconnection to requestStmtId when broke pip (#543)
     new c560e76  add fix start script

The 5 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 README.md                                          |  8 +--
 RELEASE_NOTES.md                                   |  1 +
 client-py/readme.md                                |  2 +-
 client-py/src/client_example.py                    | 65 +++++++++++-----------
 .../src/assembly/resources/sbin/start-client.bat   |  3 +
 client/src/assembly/resources/sbin/start-client.sh |  2 +
 .../4-Client/1-Command Line Interface (CLI).md     |  5 +-
 .../4-Client/1-Command Line Interface (CLI).md     |  6 +-
 .../java/org/apache/iotdb/jdbc/IoTDBStatement.java | 36 +++++++-----
 server/src/assembly/resources/conf/iotdb-env.sh    | 23 +++++++-
 .../src/assembly/resources/sbin/start-server.bat   | 37 ++++++------
 server/src/assembly/resources/sbin/start-server.sh | 16 ------
 12 files changed, 113 insertions(+), 91 deletions(-)


[incubator-iotdb] 05/05: add fix start script

Posted by qi...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

qiaojialin pushed a commit to branch rel/0.9
in repository https://gitbox.apache.org/repos/asf/incubator-iotdb.git

commit c560e76a3f1c673dc2400ca58b01aed085d9e284
Author: qiaojialin <64...@qq.com>
AuthorDate: Sat Nov 16 19:43:08 2019 +0800

    add fix start script
---
 RELEASE_NOTES.md | 1 +
 1 file changed, 1 insertion(+)

diff --git a/RELEASE_NOTES.md b/RELEASE_NOTES.md
index 7b575c0..270b70c 100644
--- a/RELEASE_NOTES.md
+++ b/RELEASE_NOTES.md
@@ -112,6 +112,7 @@
 * IOTDB-301 Bug Fix: executing "count nodes root" in client gets "Msg:3"
 * Fix Dynamic Config when Creating Existing SG or Time-series
 * Fix start-walchecker scripts for letting user define the wal folder
+* Fix start script to set JAVA_HOME
 
 
 # Apache IoTDB (incubating) 0.8.1


[incubator-iotdb] 01/05: Correct python example (#561)

Posted by qi...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

qiaojialin pushed a commit to branch rel/0.9
in repository https://gitbox.apache.org/repos/asf/incubator-iotdb.git

commit 4c1205c799ef7703f44b6b0541836dec1ba9a467
Author: Jackie Tien <ja...@foxmail.com>
AuthorDate: Sat Nov 16 11:23:50 2019 +0800

    Correct python example (#561)
    
    * correct python example
    
    (cherry picked from commit fe0b6275aa90329d665d04f60b82589804826c91)
---
 client-py/readme.md             |  2 +-
 client-py/src/client_example.py | 65 +++++++++++++++++++++--------------------
 2 files changed, 34 insertions(+), 33 deletions(-)

diff --git a/client-py/readme.md b/client-py/readme.md
index 9d849db..492b25c 100644
--- a/client-py/readme.md
+++ b/client-py/readme.md
@@ -20,7 +20,7 @@
 -->
 
 # Python connection
-## introduction
+## Introduction
 This is an example of how to connect to IoTDB with python, using the thrift rpc interfaces. Things 
 are almost the same on Windows or Linux, but pay attention to the difference like path separator.
 
diff --git a/client-py/src/client_example.py b/client-py/src/client_example.py
index 2d4188b..6926e17 100644
--- a/client-py/src/client_example.py
+++ b/client-py/src/client_example.py
@@ -17,6 +17,7 @@
 #
 
 import sys, struct
+
 sys.path.append("../target")
 
 from thrift.protocol import TBinaryProtocol
@@ -26,44 +27,45 @@ from rpc.TSIService import Client, TSCreateTimeseriesReq, TSInsertionReq, \
     TSBatchInsertionReq, TSExecuteStatementReq, \
     TS_SessionHandle, TSHandleIdentifier, TSOpenSessionReq, TSQueryDataSet, \
     TSFetchResultsReq, TSCloseOperationReq, \
-    TSCloseSessionReq, TSProtocolVersion
+    TSCloseSessionReq
+from rpc.ttypes import TSProtocolVersion
 
 TSDataType = {
-    'BOOLEAN' : 0,
-    'INT32' : 1,
-    'INT64' : 2,
-    'FLOAT' : 3,
-    'DOUBLE' : 4,
-    'TEXT' : 5
+    'BOOLEAN': 0,
+    'INT32': 1,
+    'INT64': 2,
+    'FLOAT': 3,
+    'DOUBLE': 4,
+    'TEXT': 5
 }
 
 TSEncoding = {
-    'PLAIN' : 0,
-    'PLAIN_DICTIONARY' : 1,
-    'RLE' : 2,
-    'DIFF' : 3,
-    'TS_2DIFF' : 4,
-    'BITMAP' : 5,
-    'GORILLA' : 6,
-    'REGULAR' : 7
+    'PLAIN': 0,
+    'PLAIN_DICTIONARY': 1,
+    'RLE': 2,
+    'DIFF': 3,
+    'TS_2DIFF': 4,
+    'BITMAP': 5,
+    'GORILLA': 6,
+    'REGULAR': 7
 }
 
 Compressor = {
-    'UNCOMPRESSED' : 0,
-    'SNAPPY' : 1,
-    'GZIP' : 2,
-    'LZO' : 3,
-    'SDT' : 4,
-    'PAA' : 5,
-    'PLA' : 6
+    'UNCOMPRESSED': 0,
+    'SNAPPY': 1,
+    'GZIP': 2,
+    'LZO': 3,
+    'SDT': 4,
+    'PAA': 5,
+    'PLA': 6
 }
 
 
 def convertQueryDataSet(queryDataSet, dataTypeList):
     bytes = queryDataSet.values
     row_count = queryDataSet.rowCount
-    time_bytes = bytes[:8*row_count]
-    value_bytes = bytes[8*row_count:]
+    time_bytes = bytes[:8 * row_count]
+    value_bytes = bytes[8 * row_count:]
     time_unpack_str = '>' + str(row_count) + 'q'
     records = []
     times = struct.unpack(time_unpack_str, time_bytes)
@@ -183,9 +185,9 @@ if __name__ == '__main__':
     # insert a single row
     values = ["1", "11", "1.1", "11.1", "TRUE", "\'text0\'"]
     timestamp = 1
-    status = client.insertRow(TSInsertionReq(deviceId, measurements,
-                                             values, timestamp, stmtId))
-    print(status.statusType)
+    status = client.insert(TSInsertionReq(deviceId, measurements,
+                                          values, timestamp, stmtId))
+    print(status.status)
 
     # insert multiple rows, this interface is more efficient
     values = bytearray()
@@ -217,7 +219,7 @@ if __name__ == '__main__':
     print(status.statusType)
 
     # execute deletion (or other statements)
-    resp = client.executeStatement(TSExecuteStatementReq(handle, "DELETE FROM root.group1 where time < 2"))
+    resp = client.executeStatement(TSExecuteStatementReq(handle, "DELETE FROM root.group1 where time < 2", stmtId))
     status = resp.status
     print(status.statusType)
 
@@ -225,8 +227,7 @@ if __name__ == '__main__':
     stmt = "SELECT * FROM root.group1"
     fetchSize = 2
     # this is also for resource control, make sure different queries will not use the same id at the same time
-    queryId = 1
-    resp = client.executeQueryStatement(TSExecuteStatementReq(handle, stmt))
+    resp = client.executeQueryStatement(TSExecuteStatementReq(handle, stmt, stmtId))
     # headers
     dataTypeList = resp.dataTypeList
     print(resp.columns)
@@ -235,6 +236,8 @@ if __name__ == '__main__':
     stmtHandle = resp.operationHandle
     status = resp.status
     print(status.statusType)
+
+    queryId = resp.operationHandle.operationId.queryId
     while True:
         rst = client.fetchResults(TSFetchResultsReq(stmt, fetchSize, queryId)).queryDataSet
         records = convertQueryDataSet(rst, dataTypeList)
@@ -248,5 +251,3 @@ if __name__ == '__main__':
 
     # and do not forget to close the session before exiting
     client.closeSession(TSCloseSessionReq(handle))
-
-


[incubator-iotdb] 03/05: Fix start script (#533)

Posted by qi...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

qiaojialin pushed a commit to branch rel/0.9
in repository https://gitbox.apache.org/repos/asf/incubator-iotdb.git

commit b0ccc316429f0f95c20245384359396c34880a06
Author: SilverNarcissus <15...@smail.nju.edu.cn>
AuthorDate: Sat Nov 16 14:35:43 2019 +0800

    Fix start script (#533)
    
    * fix start script
    
    (cherry picked from commit d8415e9ab8954341f49291c025a8162274813b8f)
---
 .../src/assembly/resources/sbin/start-client.bat   |  3 ++
 client/src/assembly/resources/sbin/start-client.sh |  2 ++
 .../4-Client/1-Command Line Interface (CLI).md     |  5 ++-
 .../4-Client/1-Command Line Interface (CLI).md     |  6 ++--
 server/src/assembly/resources/conf/iotdb-env.sh    | 23 ++++++++++++--
 .../src/assembly/resources/sbin/start-server.bat   | 37 +++++++++++-----------
 server/src/assembly/resources/sbin/start-server.sh | 16 ----------
 7 files changed, 51 insertions(+), 41 deletions(-)

diff --git a/client/src/assembly/resources/sbin/start-client.bat b/client/src/assembly/resources/sbin/start-client.bat
index 24113a2..0ee4721 100755
--- a/client/src/assembly/resources/sbin/start-client.bat
+++ b/client/src/assembly/resources/sbin/start-client.bat
@@ -22,6 +22,9 @@ echo ````````````````````````
 echo Starting IoTDB Client
 echo ````````````````````````
 
+@REM You can put your env variable here
+@REM set JAVA_HOME=%JAVA_HOME%
+
 if "%OS%" == "Windows_NT" setlocal
 
 pushd %~dp0..
diff --git a/client/src/assembly/resources/sbin/start-client.sh b/client/src/assembly/resources/sbin/start-client.sh
index 4591159..48af8c2 100755
--- a/client/src/assembly/resources/sbin/start-client.sh
+++ b/client/src/assembly/resources/sbin/start-client.sh
@@ -18,6 +18,8 @@
 # under the License.
 #
 
+# You can put your env variable here
+# export JAVA_HOME=$JAVA_HOME
 
 if [ -z "${IOTDB_CLI_HOME}" ]; then
   export IOTDB_CLI_HOME="$(cd "`dirname "$0"`"/..; pwd)"
diff --git a/docs/Documentation-CHN/UserGuide/4-Client/1-Command Line Interface (CLI).md b/docs/Documentation-CHN/UserGuide/4-Client/1-Command Line Interface (CLI).md
index f4ef981..e1bcff3 100644
--- a/docs/Documentation-CHN/UserGuide/4-Client/1-Command Line Interface (CLI).md	
+++ b/docs/Documentation-CHN/UserGuide/4-Client/1-Command Line Interface (CLI).md	
@@ -44,7 +44,10 @@ IOTDB为用户提供Client/Shell工具用于启动客户端和服务端程序。
 在生成完毕之后,IoTDB的cli工具位于文件夹"client/target/iotdb-client-{project.version}"中。
 
 ## Cli  / Shell运行方式
-安装后的IoTDB中有一个默认用户:`root`,默认密码为`root`。用户可以使用该用户尝试运行IoTDB客户端以测试服务器是否正常启动。客户端启动脚本为$IOTDB_HOME/bin文件夹下的`start-client`脚本。启动脚本时需要指定运行IP和PORT。以下为服务器在本机启动,且用户未更改运行端口号的示例,默认端口为6667。若用户尝试连接远程服务器或更改了服务器运行的端口号,请在-h和-p项处使用服务器的IP和PORT。	
+安装后的IoTDB中有一个默认用户:`root`,默认密码为`root`。用户可以使用该用户尝试运行IoTDB客户端以测试服务器是否正常启动。客户端启动脚本为$IOTDB_HOME/bin文件夹下的`start-client`脚本。启动脚本时需要指定运行IP和PORT。以下为服务器在本机启动,且用户未更改运行端口号的示例,默认端口为6667。若用户尝试连接远程服务器或更改了服务器运行的端口号,请在-h和-p项处使用服务器的IP和PORT。</br>
+用户也可以在启动脚本的最前方设置自己的环境变量,如JAVA_HOME等 (对于linux用户,脚本路径为:"/sbin/start-client.sh"; 对于windows用户,脚本路径为:"/sbin/start-client.bat")
+
+
 
 Linux系统与MacOS系统启动命令如下:
 
diff --git a/docs/Documentation/UserGuide/4-Client/1-Command Line Interface (CLI).md b/docs/Documentation/UserGuide/4-Client/1-Command Line Interface (CLI).md
index d8b2a58..f306722 100644
--- a/docs/Documentation/UserGuide/4-Client/1-Command Line Interface (CLI).md	
+++ b/docs/Documentation/UserGuide/4-Client/1-Command Line Interface (CLI).md	
@@ -48,8 +48,10 @@ After installation, there is a default user in IoTDB: `root`, and the
 default password is `root`. Users can use this username to try IoTDB Cli/Shell tool. The client startup script is the `start-client` file under the \$IOTDB\_HOME/bin folder. When starting the script, you need to specify the IP and PORT. (Make sure the IoTDB server is running properly when you use Cli/Shell tool to connect it.)
 
 Here is an example where the server is started locally and the user has not changed the running port. The default port is
-6667. If you need to connect to the remote server or changes
-the port number of the server running, set the specific IP and PORT at -h and -p.
+6667 </br>
+If you need to connect to the remote server or changes
+the port number of the server running, set the specific IP and PORT at -h and -p.</br>
+You also can set your own environment variable at the front of the start script ("/sbin/start-client.sh" for linux and "/sbin/start-client.bat" for windows)
 
 The Linux and MacOS system startup commands are as follows:
 
diff --git a/server/src/assembly/resources/conf/iotdb-env.sh b/server/src/assembly/resources/conf/iotdb-env.sh
index 75f01fc..3d8e39b 100755
--- a/server/src/assembly/resources/conf/iotdb-env.sh
+++ b/server/src/assembly/resources/conf/iotdb-env.sh
@@ -18,6 +18,8 @@
 # under the License.
 #
 
+# You can put your env variable here
+# export JAVA_HOME=$JAVA_HOME
 
 calculate_heap_sizes()
 {
@@ -92,8 +94,25 @@ calculate_heap_sizes()
 }
 
 
+# find java in JAVA_HOME
+if [ -n "$JAVA_HOME" ]; then
+    for java in "$JAVA_HOME"/bin/amd64/java "$JAVA_HOME"/bin/java; do
+        if [ -x "$java" ]; then
+            JAVA="$java"
+            break
+        fi
+    done
+else
+    JAVA=java
+fi
+
+if [ -z $JAVA ] ; then
+    echo Unable to find java executable. Check JAVA_HOME and PATH environment variables.  > /dev/stderr
+    exit 1;
+fi
+
 # Determine the sort of JVM we'll be running on.
-java_ver_output=`"${JAVA:-java}" -version 2>&1`
+java_ver_output=`"$JAVA" -version 2>&1`
 jvmver=`echo "$java_ver_output" | grep '[openjdk|java] version' | awk -F'"' 'NR==1 {print $2}' | cut -d\- -f1`
 JVM_VERSION=${jvmver%_*}
 JVM_PATCH_VERSION=${jvmver#*_}
@@ -145,5 +164,3 @@ IOTDB_JMX_OPTS="$IOTDB_JMX_OPTS -Xmx${MAX_HEAP_SIZE}"
 echo "Maximum memory allocation pool = ${MAX_HEAP_SIZE}B, initial memory allocation pool = ${HEAP_NEWSIZE}B"
 echo "If you want to change this configuration, please check conf/iotdb-env.sh(Unix or OS X, if you use Windows, check conf/iotdb-env.bat)."
 
-# You can put your env variable here
-# export JAVA_HOME=$JAVA_HOME
diff --git a/server/src/assembly/resources/sbin/start-server.bat b/server/src/assembly/resources/sbin/start-server.bat
index 05f15fb..534bdf2 100755
--- a/server/src/assembly/resources/sbin/start-server.bat
+++ b/server/src/assembly/resources/sbin/start-server.bat
@@ -27,8 +27,25 @@ set "FULL_VERSION="
 set "MAJOR_VERSION="
 set "MINOR_VERSION="
 
+if "%OS%" == "Windows_NT" setlocal
+
+pushd %~dp0..
+if NOT DEFINED IOTDB_HOME set IOTDB_HOME=%cd%
+popd
+
+set IOTDB_CONF=%IOTDB_HOME%\conf
+set IOTDB_LOGS=%IOTDB_HOME%\logs
+
+IF EXIST "%IOTDB_CONF%\iotdb-env.bat" (
+    CALL "%IOTDB_CONF%\iotdb-env.bat"
+    ) ELSE (
+    echo "can't find %IOTDB_CONF%\iotdb-env.bat"
+    )
 
-for /f tokens^=2-5^ delims^=.-_+^" %%j in ('java -fullversion 2^>^&1') do (
+if NOT DEFINED MAIN_CLASS set MAIN_CLASS=org.apache.iotdb.db.service.IoTDB
+if NOT DEFINED JAVA_HOME goto :err
+
+for /f tokens^=2-5^ delims^=.-_+^" %%j in ('%JAVA_HOME%\bin\java -fullversion 2^>^&1') do (
 	set "FULL_VERSION=%%j-%%k-%%l-%%m"
 	IF "%%j" == "1" (
 	    set "MAJOR_VERSION=%%k"
@@ -48,24 +65,6 @@ IF NOT %JAVA_VERSION% == 8 (
 	)
 )
 
-if "%OS%" == "Windows_NT" setlocal
-
-pushd %~dp0..
-if NOT DEFINED IOTDB_HOME set IOTDB_HOME=%cd%
-popd
-
-set IOTDB_CONF=%IOTDB_HOME%\conf
-set IOTDB_LOGS=%IOTDB_HOME%\logs
-
-IF EXIST "%IOTDB_CONF%\iotdb-env.bat" (
-    CALL "%IOTDB_CONF%\iotdb-env.bat"
-    ) ELSE (
-    echo "can't find %IOTDB_CONF%\iotdb-env.bat"
-    )
-
-if NOT DEFINED MAIN_CLASS set MAIN_CLASS=org.apache.iotdb.db.service.IoTDB
-if NOT DEFINED JAVA_HOME goto :err
-
 @REM -----------------------------------------------------------------------------
 @REM JVM Opts we'll use in legacy run or installation
 set JAVA_OPTS=-ea^
diff --git a/server/src/assembly/resources/sbin/start-server.sh b/server/src/assembly/resources/sbin/start-server.sh
index e9e46ad..ed5e826 100755
--- a/server/src/assembly/resources/sbin/start-server.sh
+++ b/server/src/assembly/resources/sbin/start-server.sh
@@ -36,22 +36,6 @@ else
     echo "can't find $IOTDB_CONF/iotdb-env.sh"
 fi
 
-if [ -n "$JAVA_HOME" ]; then
-    for java in "$JAVA_HOME"/bin/amd64/java "$JAVA_HOME"/bin/java; do
-        if [ -x "$java" ]; then
-            JAVA="$java"
-            break
-        fi
-    done
-else
-    JAVA=java
-fi
-
-if [ -z $JAVA ] ; then
-    echo Unable to find java executable. Check JAVA_HOME and PATH environment variables.  > /dev/stderr
-    exit 1;
-fi
-
 CLASSPATH=""
 for f in ${IOTDB_HOME}/lib/*.jar; do
   CLASSPATH=${CLASSPATH}":"$f


[incubator-iotdb] 04/05: [IOTDB-300]reconnection to requestStmtId when broke pip (#543)

Posted by qi...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

qiaojialin pushed a commit to branch rel/0.9
in repository https://gitbox.apache.org/repos/asf/incubator-iotdb.git

commit 143badd4a24bf2b2266d19b9c085acf84675a694
Author: Dawei Liu <13...@qq.com>
AuthorDate: Sat Nov 16 14:37:25 2019 +0800

    [IOTDB-300]reconnection to requestStmtId when broke pip (#543)
    
    (cherry picked from commit ef16fad43aff6e907539cf6a2ec76c6433b969ad)
---
 .../java/org/apache/iotdb/jdbc/IoTDBStatement.java | 36 ++++++++++++++--------
 1 file changed, 23 insertions(+), 13 deletions(-)

diff --git a/jdbc/src/main/java/org/apache/iotdb/jdbc/IoTDBStatement.java b/jdbc/src/main/java/org/apache/iotdb/jdbc/IoTDBStatement.java
index 481bcaf..ee7ded2 100644
--- a/jdbc/src/main/java/org/apache/iotdb/jdbc/IoTDBStatement.java
+++ b/jdbc/src/main/java/org/apache/iotdb/jdbc/IoTDBStatement.java
@@ -196,9 +196,7 @@ public class IoTDBStatement implements Statement {
     try {
       return executeSQL(sql);
     } catch (TException e) {
-      boolean flag = connection.reconnect();
-      reInit();
-      if (flag) {
+      if (reConnect()) {
         try {
           return executeSQL(sql);
         } catch (TException e2) {
@@ -337,9 +335,7 @@ public class IoTDBStatement implements Statement {
     try {
       return executeBatchSQL();
     } catch (TException e) {
-      boolean flag = connection.reconnect();
-      reInit();
-      if (flag) {
+      if (reConnect()) {
         try {
           return executeBatchSQL();
         } catch (TException e2) {
@@ -394,9 +390,7 @@ public class IoTDBStatement implements Statement {
     try {
       return executeQuerySQL(sql);
     } catch (TException e) {
-      boolean flag = connection.reconnect();
-      reInit();
-      if (flag) {
+      if (reConnect()) {
         try {
           return executeQuerySQL(sql);
         } catch (TException e2) {
@@ -434,9 +428,7 @@ public class IoTDBStatement implements Statement {
     try {
       return executeUpdateSQL(sql);
     } catch (TException e) {
-      boolean flag = connection.reconnect();
-      reInit();
-      if (flag) {
+      if (reConnect()) {
         try {
           return executeUpdateSQL(sql);
         } catch (TException e2) {
@@ -644,7 +636,25 @@ public class IoTDBStatement implements Statement {
     try {
       this.stmtId = client.requestStatementId();
     } catch (TException e) {
-      throw new SQLException("Cannot get id for statement", e);
+      if (reConnect()) {
+        try {
+          this.stmtId = client.requestStatementId();
+        } catch (TException e2) {
+          throw new SQLException(
+                  "Cannot get id for statement after reconnecting. please check server status",
+                  e2);
+        }
+      } else {
+        throw new SQLException(
+                "Cannot get id for statement after reconnecting. please check server status", e);
+      }
     }
   }
+
+
+  private boolean reConnect(){
+    boolean flag = connection.reconnect();
+    reInit();
+    return flag;
+  }
 }


[incubator-iotdb] 02/05: update readme (#556)

Posted by qi...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

qiaojialin pushed a commit to branch rel/0.9
in repository https://gitbox.apache.org/repos/asf/incubator-iotdb.git

commit 780d250a920766be3b1cb9f5ac6a58df6acb2559
Author: Boris <zh...@gmail.com>
AuthorDate: Sat Nov 16 14:34:36 2019 +0800

    update readme (#556)
    
    (cherry picked from commit 2bf380aa4aac4a32f198e3f0f34145fd3bba4d00)
---
 README.md | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/README.md b/README.md
index 204b686..2cb197e 100644
--- a/README.md
+++ b/README.md
@@ -337,10 +337,10 @@ Time,root.fit.d1.s1,root.fit.d1.s2,root.fit.d2.s1,root.fit.d2.s3,root.fit.p.s1
 ### Run import shell
 ```
 # Unix/OS X
-> $IOTDB_CLI_HOME/tools/import-csv.sh -h <ip> -p <port> -u <username> -pw <password> -f <xxx.csv>
+> tools/import-csv.sh -h <ip> -p <port> -u <username> -pw <password> -f <xxx.csv>
 
 # Windows
-> $IOTDB_CLI_HOME\tools\import-csv.bat -h <ip> -p <port> -u <username> -pw <password> -f <xxx.csv>
+> tools\import-csv.bat -h <ip> -p <port> -u <username> -pw <password> -f <xxx.csv>
 ```
 
 ### Error data file
@@ -352,10 +352,10 @@ Time,root.fit.d1.s1,root.fit.d1.s2,root.fit.d2.s1,root.fit.d2.s3,root.fit.p.s1
 ### Run export shell
 ```
 # Unix/OS X
-> $IOTDB_CLI_HOME/tools/export-csv.sh -h <ip> -p <port> -u <username> -pw <password> -td <directory> [-tf <time-format>]
+> tools/export-csv.sh -h <ip> -p <port> -u <username> -pw <password> -td <directory> [-tf <time-format>]
 
 # Windows
-> $IOTDB_CLI_HOME\tools\export-csv.bat -h <ip> -p <port> -u <username> -pw <password> -td <directory> [-tf <time-format>]
+> tools\export-csv.bat -h <ip> -p <port> -u <username> -pw <password> -td <directory> [-tf <time-format>]
 ```
 
 ### Input query