Hi Kevin, Personally I do not use the "w.exe" gui. I manage all tomcats via Services, and update the service.bat file if any registry/config settings etc need to be changed, so that we can manage changes/roll backs via SVN. This also makes it simpler since we have many TCs on same OS.
So, I recommend you download the .ZIP version, and install the service using services.bat I also rename the tomcat6 to whatever service name I need, so that I can install multiple tomcats on the same server OS. Via the services.bat you can also change the logging path, jvm, set threads size, memory, etc. e.g. of our services.bat if this helps you out. @echo off if "%OS%" == "Windows_NT" setlocal rem --------------------------------------------------------------------------- rem $Id: service.bat 908749 2010-02-10 23:26:42Z markt $ rem --------------------------------------------------------------------------- rem Guess CATALINA_HOME if not defined set "CURRENT_DIR=%cd%" if not "%CATALINA_HOME%" == "" goto gotHome set "CATALINA_HOME=%cd%" if exist "%CATALINA_HOME%\bin\Secure02Web64.exe" goto okHome rem CD to the upper dir cd .. set "CATALINA_HOME=%cd%" :gotHome if exist "%CATALINA_HOME%\bin\Secure02Web64.exe" goto okHome echo The tomcat.exe was not found... echo The CATALINA_HOME environment variable is not defined correctly. echo This environment variable is needed to run this program goto end rem Make sure prerequisite environment variables are set, we added specific JAVA_HOME64 path rem typically, JAVA_HOME64=C:\Program Files\Java\jdk1.6.0_17 - NOTE WE USE the JDK so we use server mode if not "%JAVA_HOME64%" == "" goto okHome echo The JAVA_HOME64 environment variable is not defined echo This environment variable is needed to run this program goto end :okHome if not "%CATALINA_BASE%" == "" goto gotBase set "CATALINA_BASE=%CATALINA_HOME%" :gotBase set "EXECUTABLE=%CATALINA_HOME%\bin\Secure02Web64.exe" rem Set default Service name set SERVICE_NAME=Secure02Web64 set PR_DISPLAYNAME=Secure02Web64 if "%1" == "" goto displayUsage if "%2" == "" goto setServiceName set SERVICE_NAME=%2 set PR_DISPLAYNAME=Secure02Web64 %2 :setServiceName if %1 == install goto doInstall if %1 == remove goto doRemove if %1 == uninstall goto doRemove echo Unknown parameter "%1" :displayUsage echo. echo Usage: service.bat install/remove [service_name] goto end :doRemove rem Remove the service "%EXECUTABLE%" //DS//%SERVICE_NAME% echo The service '%SERVICE_NAME%' has been removed goto end :doInstall rem Install the service echo Installing the service '%SERVICE_NAME%' ... echo Using CATALINA_HOME: "%CATALINA_HOME%" echo Using CATALINA_BASE: "%CATALINA_BASE%" echo Using JAVA_HOME64: "%JAVA_HOME64%" rem Use the environment variables as an example rem Each command line option is prefixed with PR_ set PR_DESCRIPTION=Secure Web 02 TC 6.0.28 set "PR_INSTALL=%EXECUTABLE%" set "PR_LOGPATH=%CATALINA_BASE%\logs" set "PR_CLASSPATH=%CATALINA_BASE%\bin\tomcat-juli.jar;%CATALINA_HOME%\bin\bootstrap.jar" rem Set the server jvm from JAVA_HOME64 set "PR_JVM=%JAVA_HOME64%\jre\bin\server\jvm.dll" if exist "%PR_JVM%" goto foundJvm rem Set the client jvm from JAVA_HOME64 set "PR_JVM=%JAVA_HOME64%\jre\bin\client\jvm.dll" if exist "%PR_JVM%" goto foundJvm set PR_JVM=auto :foundJvm echo Using JVM: "%PR_JVM%" "%EXECUTABLE%" //IS//%SERVICE_NAME% --StartClass org.apache.catalina.startup.Bootstrap --StopClass org.apache.catalina.startup.Bootstrap --StartParams start --StopParams stop if not errorlevel 1 goto installed echo Failed installing '%SERVICE_NAME%' service goto end :installed rem Clear the environment variables. They are not needed any more. set PR_DISPLAYNAME= set PR_DESCRIPTION= set PR_INSTALL= set PR_LOGPATH= set PR_CLASSPATH= set PR_JVM= rem Set extra parameters "%EXECUTABLE%" //US//%SERVICE_NAME% --JvmOptions "-Dcatalina.base=%CATALINA_BASE%;-Dcatalina.home=%CATALINA_HOME%;-Djava.endorsed.dirs=%CATALINA_HOME%\endorsed" --StartMode jvm --StopMode jvm rem More extra parameters set "PR_LOGPATH=%CATALINA_BASE%\logs" set PR_STDOUTPUT=auto set PR_STDERROR=auto "%EXECUTABLE%" //US//%SERVICE_NAME% ++JvmOptions "-XX:MaxPermSize=256m;-Djava.io.tmpdir=%CATALINA_BASE%\temp;-Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager;-Djava.util.logging.config.file=%CATALINA_BASE%\conf\logging.properties;-D64" --JvmMs 512 --JvmMx 3072 --JvmSs 192 echo The service '%SERVICE_NAME%' has been installed. :end cd "%CURRENT_DIR%" Cheers Andrew On Tue, Aug 10, 2010 at 3:21 AM, Stewart, Kevin L. (GSFC-417.0)[CONSTELLATION SOFTWARE ENGINEERING] <kevin.l.stew...@nasa.gov> wrote: > Hi, I've been looking on the web and the Tomcat wiki and haven't found any > solution to this problem. > > I have a 64-bit Windows 2008 server with Java 1.6_20 (64-bit) and 64-bit > tomcat 6.0.26 (6.0.29 also) installed as a service. I also have a Liferay > portal that I need to install. But I am having problems with the startup. > (BTW, I use the tomcat6w.exe gui mostly.) If I use startmode=jvm, the Spring > framework in Liferay loops until I get a StackOverflowException, no matter > the stack size. However, if I start with startmode=java the Spring framework > initializes correctly, however some logs appear in the java directory instead > of the Tomcat one even though the user.dir is set to Tomcat. Further, when > startmode=java the stop service on tomcat6w.exe returns successful after a > long wait, but the Tomcat server is still actually running. I have to > manually kill the Java process that Tomcat is running in. My choices seem to > be having a non-functional Tomcat or an unstable one. > > I wrote a cheap JSP that dumps out all the session, request and system > properties. I've ruled all the differences out that I could (server lib > path, classpath, etc). The only one I couldn't was: > > Property: "sun.java.launcher" value = "SUN_STANDARD" > > My first question is why does the startmode make such a difference in the > behavior of Tomcat? Secondly, how can I either stabilize startmode=java or > better yet get startmode=jvm working? > > Kevin L. Stewart > Sr. Software Lead, GOES V3 > Constellation Software Engineering > NASA GSFC, Code 417 > > --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org