无法启动sonarqube 6.1

时间:2016-12-12 07:25:52

标签: java sonarqube sonar-runner sonarqube-scan sonarqube5.1

安装了sonarqube 6.1, 在StartSonar.bat文件中将JAVA_HOME设置为C:\ JDK \ jdk1.8.0_92,并在路径变量中添加C:\ JDK \ _jdk1.8.0_92 \ bin

尝试开始收到以下错误时

Setting JAVA_HOME
PATH: C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System3
2\WindowsPowerShell\v1.0\;C:\Program  Files\TortoiseSVN\bin;C:\svnrepository\bin;
C:\SVN\bin;C:\apache-maven-3.0.4\bin;C:\Sonar\sonar-runner-2.0\bin;C:\JDK\jdk1.7
.0_60\bin;C:\ANT\ant-1.8.2\bin;C:\Maven\apache-maven-3.0.4\bin;C:\JDK\jdk1.8.0_9
2/bin;
JAVA_HOME: C:\JDK\jdk1.8.0_92
wrapper  | --> Wrapper Started as Console
wrapper  | Launching a JVM...
jvm 1    | Wrapper (Version 3.2.3) http://wrapper.tanukisoftware.org
jvm 1    |   Copyright 1999-2006 Tanuki Software, Inc.  All Rights Reserved.
jvm 1    |
jvm 1    | WrapperSimpleApp: Unable to locate the class    org.sonar.application.Ap
p: java.lang.UnsupportedClassVersionError: org/sonar/application/App :   Unsupport
 ed major.minor version 52.0
jvm 1    |
jvm 1    | WrapperSimpleApp Usage:
jvm 1    |   java org.tanukisoftware.wrapper.WrapperSimpleApp {app_class}   [app_arguments]
jvm 1    |
jvm 1    | Where:
jvm 1    |   app_class:      The fully qualified class name of the application to run.
jvm 1    |   app_arguments:  The arguments that would normally be passed to the
jvm 1    |                   application.
jvm 1    | Picked up _JAVA_OPTIONS: -Xms1024m -Xmx2048m
wrapper  | <-- Wrapper Stopped

1 个答案:

答案 0 :(得分:5)

看起来您正试图在较旧版本的JVM上运行使用Java 8编译的类。是Tanuki包装器是否尊重您设置的JAVA_HOME变量?如果你在不经过包装的情况下运行它会发生什么?

见这里:How to fix java.lang.UnsupportedClassVersionError: Unsupported major.minor version

编辑:另外,我看到你的路径引用了JDK 1.7和JDK 1.8。我会尝试删除对JDK 1.7的引用,看看是否会产生影响。