Issue: The Apache Tomcat XX TomcatXX service terminated

If you encounter the following popup error message while starting
image

And in the log files you see:
The Apache Tomcat XX TomcatXX service terminated with the following service-specific error: Incorrect function.

Try to apply the following as a resolution:
This error occurs when JDK on your machine is not installed.

To resolve this:

  • Check the java version installed on the machine. Perform java -version on cmd to check

  • Check the JAVA_HOME and JRE_HOME environment variable are pointing to the correct path or not

  • Install JDK of the same version as JRE if not installed

  • Double click on the tomcat9w.exe file from apache-tomcat/bin location

  • Click on the JAVA tab and Check the Use Default option for the Java Virtual Machine option.

  • Now start the tomcat service
1 Like

This is an information blog.

1 Like