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/06/28 02:48:12 UTC

[incubator-iotdb] 01/01: fix system memory check in iotdb-env.sh

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

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

commit b88fa61c16a9cd407d6bbbe9ce8a9b5147f8ed17
Author: qiaojialin <64...@qq.com>
AuthorDate: Fri Jun 28 10:47:57 2019 +0800

    fix system memory check in iotdb-env.sh
---
 iotdb/iotdb/conf/iotdb-env.sh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/iotdb/iotdb/conf/iotdb-env.sh b/iotdb/iotdb/conf/iotdb-env.sh
index 687c4b2..567aa37 100755
--- a/iotdb/iotdb/conf/iotdb-env.sh
+++ b/iotdb/iotdb/conf/iotdb-env.sh
@@ -23,7 +23,7 @@ calculate_heap_sizes()
 {
     case "`uname`" in
         Linux)
-            system_memory_in_mb=`free -m | awk '/:/ {print $2;exit}'`
+            system_memory_in_mb=`free -m| sed -n '2p' | awk '{print $2}'`
             system_cpu_cores=`egrep -c 'processor([[:space:]]+):.*' /proc/cpuinfo`
         ;;
         FreeBSD)