The error information is as follows:
Caused by inconsistent JDK environment
Exception in thread "main" java.lang.UnsupportedClassVersionError: org/springframework/boot/loader/JarLauncher : Unsupported major.minor version 52.0
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:800)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:449)
at java.net.URLClassLoader.access$100(URLClassLoader.java:71)
at java.net.URLClassLoader$1.run(URLClassLoader.java:361)
at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
at java.lang.ClassLoader.loadClass(ClassLoader.java:425)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
at java.lang.ClassLoader.loadClass(ClassLoader.java:358)
at sun.launcher.LauncherHelper.checkAndLoadMain(LauncherHelper.java:482)
Solution:
First, download the appropriate JDK on the Linux server. I have re downloaded JDK1.8, and the original 1.7 has been installed
Start command:
To find the installation directory of JDK, start the project through the corresponding version of JDK
nohup /usr/local/jdk8/bin/java -jar -Dspring.profiles.active=test read.jar &
Read More:
- [Solved] mvn -v error: Unsupported major. minor version 51.0
- [Solved] JAVA Project Import jstl Error: java.lang.NoClassDefFoundError: javax/servlet/jsp/tagext/TagLibraryValidator
- Idea create Maven project Error: [error] no longer supports source option 1.5. Please use version 1.6 or higher, and the idea reports an error: error: Java does not support the error of release version 5
- [Solved] java.sql.SQLException: Unsupported character encoding ‘utf-8
- How to Solve Linux connecte to the old version of SQL Server Error
- ERROR launching ‘JD-GUI‘ No suitable Java version [How to Solve]
- How to Solve Java Runtime (class file version 53.0)ERROR
- [Solved] weblogic12c start the project error: BeanFactoryAware is missing
- [Solved] IDEA Start Porject Error: java: Compilation failed: internal java compiler error
- How to Solve JD-GUI Start Error (Mac ARM Version)
- Spring Security Upgrade to Version 5.5.7, 5.6.4 or Above to Startup Error (Version incompatibility)
- Twitter’s distributed self increasing ID algorithm snowflake (Java version)
- [Solved] Springboot project introduces Font library error: java.awt.fontformatexception: bad table, tag = XXXXXX
- IDEA-Error java error release version 5 not supported (How To Fix)
- [ERROR] Failed to execute goal on project simple-project: Could not resolve dependencies for project
- [Solved] swagger Failed to start bean ‘documentationPluginsBootstrapper‘; nested exception is java.lang.NullP
- [Solved] the resource is not on the build path of a java project
- [Solved] Failed to start bean ‘eurekaAutoServiceRegistration‘; nested exception is java.lang.NullPointerExce
- JAVA Code Start Exception Error View Does Not Exsit [Solved]
- Mongodb java version 3.X, prompt “XXX (an encryption algorithm) is not available” when there is a user name and password