error when starting the apache tomcat 7.0 tomcat 7 service on local computer
Hi,
We have an issue with creating and starting a new apache tomacat service for Rational Requirements Composer tool.
Steps we followed are:
1. Followed the link - http://pic.dhe.ibm.com/infocenter/clmhelp/v4r0m6/index.jsp?topic= Configuring Apache Tomcat server to run as a Windows service
2. First we verified that there is no another installed service by running command.
E:\Program Files\IBM\JazzTeamServer406\server\tomcat\bin>sc query tomcat7
[SC] EnumQueryServicesStatus:OpenService FAILED 1060:
The specified service does not exist as an installed service.
3. Installed the service
E:\Program Files\IBM\JazzTeamServer406\server\tomcat\bin>service.bat install tom
cat7
Neither the JAVA_HOME nor the JRE_HOME environment variable is defined
Service will try to guess them from the registry.
Installing the service 'tomcat7' ...
Using CATALINA_HOME: "E:\PROGRA~2\IBM\JazzTeamServer406\server\tomcat"
Using CATALINA_BASE: "E:\PROGRA~2\IBM\JazzTeamServer406\server\tomcat"
Using JAVA_HOME: ""
Using JRE_HOME: ""
Using JVM: "auto"
The service 'tomcat7' has been installed.
4. After setting all the other settings as per the info center guide. Stopped the RRC server using Stop Script then restarted the server and in the services console the apache service appear to be in the Stopped State.
It is throwing the below error when tried to start.
|
5 answers
As you can see, the installer could not pick up a Java runtime when it installed the service. Without it, Tomcat cannot run. You can remove the service, add the environment variable before running the installer again. You can also follow the steps below.
1. Run tomcat\bin\tomcat7w.exe to launch the control panel. 2. Switch to the Java tab. 3. Uncheck "Use Default". 4. Specify the correct JVM. In your case, it should be E:\Program Files\IBM\JazzTeamServer406\server\jre\bin\j9vm\jvm.dll 5. Click OK to save changes and close the control panel. 6. Start the service. |
After having configured in a similar way on another machine we are getting the below error. Looks a little different from the above. Here also the server is not getting started.
Comments
Donald Nong
commented Sep 24 '14, 12:11 a.m.
If you have verified that it's not the same issue, you should at least check the System Event Log as suggested by the error message, or check catalina.out file as you previously did.
|
Having checked the tomcat7-stderr.2014-09-24.log file I see the below error.
2014-09-24 00:06:51 Commons Daemon procrun stderr initialized
JVMJ9VM015W Initialization error for library j9gc24(2): Failed to instantiate heap; 4G requested
commons-daemon.2014-09-24.log file says
[2014-09-24 00:56:46] [info] Running 'tomcat7' Service...
[2014-09-24 00:56:46] [info] Starting service...
[2014-09-24 00:56:46] [error] CreateJavaVM Failed
[2014-09-24 00:56:46] [error] Failed to start Java
[2014-09-24 00:56:46] [error] ServiceStart returned 4
[2014-09-24 00:56:46] [info] Run service finished.
[2014-09-24 00:56:46] [info] Commons Daemon procrun finished
Referring to the correct documentation- (Configure Apache Tomcat server to run as a Windows service)
https://www-01.ibm.com/support/knowledgecenter/SSYMRC_4.0.6/com.ibm.jazz.install.doc/topics/roadmap_form.html?cp=SSYMRC_4.0.6&lang=en
Option being set on Java are as below
Java Virtual Machine
E:\PROGRA~1\IBM\JazzTeamServer\server\jre\bin\j9vm\jvm.dll
Java Class Path
E:\PROGRA~1\IBM\JazzTeamServer\server\tomcat\bin\bootstrap.jar;E:\PROGRA~1\IBM\JazzTeamServer\server\tomcat\bin\tomcat-juli.jar;E:\PROGRA~1\IBM\JazzTeamServer\server\tomcat\bin\tomcat-juli.jar
Java Options
-Dcatalina.base=E:\PROGRA~1\IBM\JazzTeamServer\server\tomcat
-Dcatalina.home=E:\PROGRA~1\IBM\JazzTeamServer\server\tomcat
-Djava.endorsed.dirs=E:\PROGRA~1\IBM\JazzTeamServer\server\tomcat\endorsed
-Djava.io.tmpdir=E:\PROGRA~1\IBM\JazzTeamServer\server\tomcat\temp
-Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager
-Djava.util.logging.config.file=E:\PROGRA~1\IBM\JazzTeamServer\server\tomcat\conf\logging.properties
-DJAZZ_HOME=file:///E:/PROGRA~1/IBM/JazzTeamServer/server/conf
-Djava.awt.headless=true
-Dorg.eclipse.emf.ecore.plugin.EcorePlugin.doNotLoadResourcesPlugin=true
-Dcom.ibm.team.repository.tempDir=E:/PROGRA~1/IBM/JazzTeamServer/server\tomcat\temp
-Djazz.connector.sslProtocol=SSL_TLS
-Djazz.connector.algorithm=IbmX509
-Dlog4j.configuration=file:///E:/PROGRA~1/IBM/JazzTeamServer/server/conf/startup_log4j.properties
-Xgcpolicy:gencon
-Xcompressedrefs
-Xgc:preferredHeapBase=0x100000000
-XX:MaxDirectMemorySize=1G
-Xmx4G
-Xms4G
-Xmn512M
-DSQLSERVER_JDBC_DRIVER_FILE=E:\Program Files\IBM\JazzTeamServer\server\sqlserver\sqljdbc4.jar
Not sure what has gone wrong here.
Comments 1
Donald Nong
commented Sep 24 '14, 1:42 a.m.
It seems that you don't have enough physical memory to support the requested heap size. Try to lower the heap size (-Xmx and -Xms) first to confirm.
|
Hi,
After reducing the -Xmx and -Xms value to 2G from 4G. After restarting the server when verified the Apache Tomcat Service start running.
Thanks for the suggestion.
|
Glad you found a solution :)
I am not as lucky... :(
I am preparing for a customer setup with CLM v6.0.1 and tomcat as service, and I am running into trouble when it comes to the installation of the service.
Having ensured all settings are done as per documentation, I get an error during installation due to not having set JRE_HOME not JAVA_HOME. Using the tomcat7w.exe for configuration, I have defined the JVM explicitly as IBM JRE:
Problem is there is no mentioning of JAVA or JRE installation in the configuration process. But it is clearly lacking...?
Neither the JAVA_HOME nor the JRE_HOME environment variable is defined Service will try to guess them from the registry. Installing the service 'tomcat7' ... Using CATALINA_HOME: "C:\Program Files\IBM\JazzTeamServer\server\tomcat" Using CATALINA_BASE: "C:\Program Files\IBM\JazzTeamServer\server\tomcat" Using JAVA_HOME: "" Using JRE_HOME: "" Warning: Neither 'server' nor 'client' jvm.dll was found at JRE_HOME. Using JVM: "auto" Failed installing 'tomcat7' service If I try to set JRE_HOME explicity to .../jre I get an error on JAVA_HOME which must point to a JDK (and none is installed, to be sure. Should it really be needed to have independent JAVA installed? Comments
Donald Nong
commented Feb 15 '16, 1:41 a.m.
You don't need to specify JAVA_HOME or JRE_HOME for this task, as you will specify the JVM after the service is installed. It's not related to the failure of installing the service, I believe. Make sure you run the command in an elevated command prompt. If you are using Windows Server 2012, you may even have encountered something new.
|
Your answer
Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.