• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Tomcat 3.3 jk_nt_service & TOMCAT_OPTS

 
Dan Gunawan
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all,

I'm currently having some problem on which whenever my instance of Tomcat is started using Windows service, it's not picking up the value of whatever parameter I have previously defined on TOMCAT_OPTS variable in my tomcat.bat file.

However, if I start Tomcat from clicking the startup.bat from %TOMCAT_HOME%/bin directory, I can access my parameter defined on TOMCAT_OPTS variable.

Does anyone know on how to get around this? I can't upgrade Tomcat or JDK as I'm supposed to look at a problem being experienced on an old system.

I'm carrying out this test on a dev machine with Win2000, JDK1.4 and using Tomcat's HelloWorld servlet example to retrieve the variable.

From HelloWorldExample.java
out.println("System.getProperty(): " + System.getProperty("aaa.test.aaa") );

From wrapper.properties file:
wrapper.cmd_line="$(wrapper.javabin)" -Djava.security.policy=="$(wrapper.tomcat_policy)" -Dtomcat.home="$(wrapper.tomcat_home)" -classpath $(wrapper.class_path) $(wrapper.startup_class) -config $(wrapper.server_xml) tomcat

From tomcat.bat file:
set TOMCAT_OPTS=-Daaa.test.aaa=C:\jakarta-tomcat-3.3.2\logs\jvm.stderr

Thanks
 
Dan Gun
Greenhorn
Posts: 26
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Answer:

put the variable definition, in my case (-Daaa.test.aaa=C:\jakarta-tomcat-3.3.2\logs\jvm.stderr), into wrapper.properties like the following:

 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic