2016-10-26 34 views
2

我正在尝试安装Accumulo。但我遇到了一个问题。使用Maven安装Accumulo时无法执行目标

这里是我使用的命令:

mvn package install -X 

这里是安装执行的最后一部分,你可以清楚地看到错误:

[INFO] ------------------------------------------------------------------------ 
[INFO] Reactor Summary: 
[INFO] 
[INFO] Apache Accumulo Project ............................ SUCCESS [ 15.329 s] 
[INFO] Apache Accumulo Fate ............................... SUCCESS [01:05 min] 
[INFO] Apache Accumulo Start .............................. FAILURE [ 7.833 s] 
[INFO] Apache Accumulo Core ............................... SKIPPED 
[INFO] Apache Accumulo Documentation ...................... SKIPPED 
[INFO] Apache Accumulo Server Base ........................ SKIPPED 
[INFO] Apache Accumulo Tracer Server ...................... SKIPPED 
[INFO] Apache Accumulo Shell .............................. SKIPPED 
[INFO] Apache Accumulo Simple Examples .................... SKIPPED 
[INFO] Apache Accumulo GC Server .......................... SKIPPED 
[INFO] Apache Accumulo Master Server ...................... SKIPPED 
[INFO] Apache Accumulo Monitor Server ..................... SKIPPED 
[INFO] Apache Accumulo Tablet Server ...................... SKIPPED 
[INFO] Apache Accumulo MiniCluster ........................ SKIPPED 
[INFO] Apache Accumulo Native Libraries ................... SKIPPED 
[INFO] Apache Accumulo Proxy .............................. SKIPPED 
[INFO] Apache Accumulo Iterator Test Harness .............. SKIPPED 
[INFO] Apache Accumulo Testing ............................ SKIPPED 
[INFO] Apache Accumulo .................................... SKIPPED 
[INFO] Apache Accumulo Maven Plugin ....................... SKIPPED 
[INFO] ------------------------------------------------------------------------ 
[INFO] BUILD FAILURE 
[INFO] ------------------------------------------------------------------------ 
[INFO] Total time: 01:30 min 
[INFO] Finished at: 2016-10-26T15:05:30+00:00 
[INFO] Final Memory: 52M/240M 
[INFO] ------------------------------------------------------------------------ 
[ERROR] Failed to execute goal org.codehaus.mojo:exec-maven-plugin:1.4.0:exec (Build Test jars) on project accumulo-start: Command execution failed. Process exited with an error: 127 (Exit value: 127) -> [Help 1] 
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.codehaus.mojo:exec-maven-plugin:1.4.0:exec (Build Test jars) on project accumulo-start: Command execution failed. 
     at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:212) 
     at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153) 
     at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145) 
     at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:116) 
     at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:80) 
     at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:51) 
     at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:128) 
     at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:307) 
     at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:193) 
     at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:106) 
     at org.apache.maven.cli.MavenCli.execute(MavenCli.java:863) 
     at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:288) 
     at org.apache.maven.cli.MavenCli.main(MavenCli.java:199) 
     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) 
     at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) 
     at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) 
     at java.lang.reflect.Method.invoke(Method.java:498) 
     at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289) 
     at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229) 
     at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415) 
     at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356) 
Caused by: org.apache.maven.plugin.MojoExecutionException: Command execution failed. 
     at org.codehaus.mojo.exec.ExecMojo.execute(ExecMojo.java:276) 
     at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:134) 
     at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:207) 
     ... 20 more 
Caused by: org.apache.commons.exec.ExecuteException: Process exited with an error: 127 (Exit value: 127) 
     at org.apache.commons.exec.DefaultExecutor.executeInternal(DefaultExecutor.java:404) 
     at org.apache.commons.exec.DefaultExecutor.execute(DefaultExecutor.java:166) 
     at org.codehaus.mojo.exec.ExecMojo.executeCommandLine(ExecMojo.java:660) 
     at org.codehaus.mojo.exec.ExecMojo.execute(ExecMojo.java:265) 
     ... 22 more 
[ERROR] 
[ERROR] 
[ERROR] For more information about the errors and possible solutions, please read the following articles: 
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException 
[ERROR] 
[ERROR] After correcting the problems, you can resume the build with the command 
[ERROR] mvn <goals> -rf :accumulo-start 

是否有包我失踪了? Ubuntu的一些错误?

操作系统: 没有LSB模块可用。 经销商ID:Ubuntu的 说明:Ubuntu的LTS 16.04.1发布 :16.04 代号:xenial

我使用Accumulo的当前版本(the master on GitHub)。

+0

不要执行'mvn package install'。这将执行一半的构建两次。 'install'包含它之前maven生命周期中的所有步骤。另外,使用'install'完全不同寻常。您可能想要构建('package')或运行完整的构建后验证步骤('verify')。请参阅https://maven.apache.org/guides/introduction/introduction-to-the-lifecycle.html – Christopher

回答

2

看起来像它的makeTestJars脚本,https://github.com/apache/accumulo/blob/master/start/src/test/shell/makeTestJars.sh的执行过程中失败了,这意味着它无法找到您的系统上这四个命令之一(MKDIR,sed的,$ JAVA_HOME /斌/ javac的,或$ JAVA_HOME/bin中/罐)。

+0

是的,在启动Hadoop时,我抛出了未设置的错误JAVA_HOME。奇怪的是,当我回声$ JAVA_HOME我有正确的价值。我不得不进入Hadoop开始bash脚本并将export JAVA_HOME = $ {JAVA_HOME}更改为我的值...然后Hadoop工作。但这仅仅是为了Hadoop。这个解决方案可能也适用于Accumulo。但是为什么当JAVA_HOME被设置时会发生这种情况? – jnbdz

+0

您必须确保JAVA_HOME已设置,并从您的shell中导出。如果已经设置了一个简单的'export JAVA_HOME'应该可以工作。 – Christopher

+0

这是在我的〜/ .bashrc这就是为什么我有点困惑。我实际上在makeTestJars.sh中添加了一个导出JAVA_HOME,但它仍然不起作用。 – jnbdz

相关问题