简体   繁体   中英

How to set HeapDumpOnOutOfMemoryError and HeapDumpPath in startup.bat file on Windows XP

Where are the and params set in the startup.bat file for Tomcat on a Windows PC? 参数? I put both params in the file as follows :

set JAVA_OPTS=-Xms100m -Xmx192m
-XX:+HeapDumpOnOutOfMemoryError 
-XX:HeapDumpPath=c:\jakarta-tomcat\webapps

call "%EXECUTABLE%" start %CMD_LINE_ARGS%

:end

Is that the area where those params should go? I'm getting the following message when I Tomcat > Tomcat时收到以下消息>

I'm not sure what part of the statement is incorrect. What am I missing here?

If you want to split a command into several lines, you have to escape the newlines.

set JAVA_OPTS=-Xms100m -Xmx192m ^
-XX:+HeapDumpOnOutOfMemoryError ^
-XX:HeapDumpPath=c:\jakarta-tomcat\webapps

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM