How to start Tomcat 7 from Windows command line in the same window?
Solution 1
I was able to run it in the same window using
catalina.bat run
Solution 2
catalina.bat run
This will do the trick. However the reason why it works lies within the file catalina.bat(for windows)/catalina.sh(for linux). Check how the action run and start blocks(:doRun and :doStart) are implemented. Both of them will start the tomcat; run
in foreground and start
in the background.
Comments
-
amphibient almost 2 years
When I run
%TOMCAT_ROOT%\bin\startup.bat
from aWindows 7
command line, it opens a new window with default command line window settings (I have them personalized). I would prefer to run it in the same command window in the same prompt and not forked off in a separate window.As you can see, the inner Tomcat window in the picture above is smaller and has a smaller font. I would like to run the server in the bigger, parent window where I executed
startup.bash
.Essentially, I would like to run it on Windows the same way it would run as a console Linux application if I ran
startup.sh
.