This is an automated email from the ASF dual-hosted git repository.
haonan pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/iotdb.git
The following commit(s) were added to refs/heads/master by this push:
new 48328e3 [ISSUE-3232] fix the bug of Memory Information in Windows
host (#3231)
48328e3 is described below
commit 48328e381ffca0f3fd997057c30c378667fa3dbe
Author: 张正明 <[email protected]>
AuthorDate: Thu May 20 13:23:50 2021 +0800
[ISSUE-3232] fix the bug of Memory Information in Windows host (#3231)
---
server/src/assembly/resources/conf/iotdb-env.bat | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/server/src/assembly/resources/conf/iotdb-env.bat
b/server/src/assembly/resources/conf/iotdb-env.bat
index 76bdea7..5926467 100644
--- a/server/src/assembly/resources/conf/iotdb-env.bat
+++ b/server/src/assembly/resources/conf/iotdb-env.bat
@@ -67,8 +67,8 @@ set system_memory_in_mb=%system_memory_in_mb:,=%
set /a half_=%system_memory_in_mb%/2
set /a quarter_=%half_%/2
-if ["%half_%"] GTR ["1024"] set half_=1024
-if ["%quarter_%"] GTR ["65536"] set quarter_=65536
+if ["%half_%"] GTR ["1024"] set %half_%=1024
+if ["%quarter_%"] GTR ["65536"] set %quarter_%=65536
if ["%half_%"] GTR ["quarter_"] (
set max_heap_size_in_mb=%half_%
@@ -87,7 +87,6 @@ IF ["%IOTDB_HEAP_OPTS%"] EQU [""] (
rem detect Java 8 or 11
IF "%JAVA_VERSION%" == "8" (
java -d64 -version >nul 2>&1
- echo Maximum memory allocation pool = %MAX_HEAP_SIZE%, initial
memory allocation pool = %HEAP_NEWSIZE%
set IOTDB_HEAP_OPTS=-Xmx%MAX_HEAP_SIZE% -Xms%HEAP_NEWSIZE%
-Xloggc:"%IOTDB_HOME%\gc.log" -XX:+PrintGCDateStamps -XX:+PrintGCDetails
goto end_config_setting
) ELSE (
@@ -106,7 +105,6 @@ for /f "tokens=1-3" %%j in ('java -version 2^>^&1') do (
@REM maximum direct memory size
set MAX_DIRECT_MEMORY_SIZE=%MAX_HEAP_SIZE%
-echo Maximum memory allocation pool = %MAX_HEAP_SIZE%, initial memory
allocation pool = %HEAP_NEWSIZE%
set IOTDB_HEAP_OPTS=-Xmx%MAX_HEAP_SIZE% -Xms%HEAP_NEWSIZE%
-Xloggc:"%IOTDB_HOME%\gc.log" -XX:+PrintGCDateStamps -XX:+PrintGCDetails
set IOTDB_HEAP_OPTS=%IOTDB_HEAP_OPTS%
-XX:MaxDirectMemorySize=%MAX_DIRECT_MEMORY_SIZE%
@@ -124,7 +122,9 @@ IF "%1" equ "printgc" (
set IOTDB_HEAP_OPTS=%IOTDB_HEAP_OPTS%
-Xlog:gc=info,heap*=trace,age*=debug,safepoint=info,promotion*=trace:file="%IOTDB_HOME%\logs\gc.log":time,uptime,pid,tid,level:filecount=10,filesize=10485760
)
)
-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).
+
@REM Maximum heap size
-@REM set MAX_HEAP_SIZE=2G
\ No newline at end of file
+@REM set MAX_HEAP_SIZE=2G
+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).
+echo Maximum memory allocation pool = %MAX_HEAP_SIZE%, initial memory
allocation pool = %HEAP_NEWSIZE%
\ No newline at end of file