java - Configuring tomcat installation-free version, unable to start, returning error code 4
扔个三星炸死你
扔个三星炸死你 2017-06-12 09:21:32
0
2
1086

JDK was installed two years ago, so I installed tomcat directly today, and then the following prompt popped up in "Computer Management>Services and Applications>Services":

I checked Don’t Ask and there are similar problems to mine, but their error types are different from mine. Newbies don’t know how to solve them. Please help me.
java version:

$ java -version
java version "1.6.0_38"
Java(TM) SE Runtime Environment (build 1.6.0_38-b05)
Java HotSpot(TM) Client VM (build 20.13-b02, mixed mode)

The following is the startup log
commons-daemon.log:

[2017-06-09 00:08:46] [info]  [ 9900] Commons Daemon procrun (1.0.15.0 32-bit) started
[2017-06-09 00:08:46] [info]  [ 9900] Service Tomcat9 name Apache Tomcat 9.0 Tomcat9
[2017-06-09 00:08:49] [info]  [ 9900] Service 'Tomcat9' installed
[2017-06-09 00:08:49] [info]  [ 9900] Commons Daemon procrun finished
[2017-06-09 00:10:01] [info]  [ 7308] Commons Daemon procrun (1.0.15.0 32-bit) started
[2017-06-09 00:10:02] [info]  [ 7308] Running 'Tomcat9' Service...
[2017-06-09 00:10:02] [info]  [ 6148] Starting service...
[2017-06-09 00:10:03] [error] [ 7920] FindClass org/apache/catalina/startup/Bootstrap failed
[2017-06-09 00:10:03] [error] [ 6148] Failed to start Java
[2017-06-09 00:10:03] [error] [ 6148] ServiceStart returned 4
[2017-06-09 00:10:03] [info]  [ 7308] Run service finished.
[2017-06-09 00:10:04] [info]  [ 7308] Commons Daemon procrun finished

tomcat9-stderr.log:


2017-06-09 00:37:41 Commons Daemon procrun stderr initialized
java.lang.UnsupportedClassVersionError: org/apache/catalina/startup/Bootstrap : Unsupported major.minor version 52.0
    at java.lang.ClassLoader.defineClass1(Native Method)
    at java.lang.ClassLoader.defineClassCond(ClassLoader.java:631)
    at java.lang.ClassLoader.defineClass(ClassLoader.java:615)
    at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:141)
    at java.net.URLClassLoader.defineClass(URLClassLoader.java:283)
    at java.net.URLClassLoader.accessrrreee0(URLClassLoader.java:58)
    at java.net.URLClassLoader.run(URLClassLoader.java:197)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
    at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
Exception in thread "main" 
扔个三星炸死你
扔个三星炸死你

reply all(2)
曾经蜡笔没有小新

Unsupported major.minor version 52.0

This version is not supported

Tomcat9 documentation writes:

The installer uses the registry to determine the base path of a Java 7 or later JRE, including the JRE installed as part of the full JDK

Java7 and above.

Peter_Zhu

Install a new version of JDK

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template