hudson.AbortException: Failed to install JDK. Exit code=2

Jenkins JIRA | First Last | 4 years ago
tip
Do you know that we can give you better hits? Get more relevant results from Samebug’s stack trace search.
  1. 0

    My steps: Base CentOS 6.0 AMI. > Install Java 7 via RPM as root. > Save as custom AMI. > Use new custom AMI for Jenkins slaves > Set up EC2 plugin as reflected in the attachment image. > Run a build, and get the following errors: Building remotely on i-0326a672 in workspace workspace/FriendList Installing tools/hudson.model.JDK/java7/jdk.sh [java7] $ tar xvzf tools/hudson.model.JDK/java7/jdk.sh tar (child): tools/hudson.model.JDK/java7/jdk.sh: Cannot open: No such file or directory tar (child): Error is not recoverable: exiting now tar: Child returned status 2 tar: Error is not recoverable: exiting now ERROR: Failed to install JDK. Exit code=2 Archiving artifacts Installing tools/hudson.model.JDK/java7/jdk.sh [java7] $ tar xvzf tools/hudson.model.JDK/java7/jdk.sh tar (child): tools/hudson.model.JDK/java7/jdk.sh: Cannot open: No such file or directory tar (child): Error is not recoverable: exiting now tar: Child returned status 2 tar: Error is not recoverable: exiting now ERROR: Failed to archive artifacts: target/*.jar hudson.AbortException: Failed to install JDK. Exit code=2 at hudson.tools.JDKInstaller.install(JDKInstaller.java:189) at hudson.tools.JDKInstaller.performInstallation(JDKInstaller.java:132) at hudson.tools.InstallerTranslator.getToolHome(InstallerTranslator.java:61) at hudson.tools.ToolLocationNodeProperty.getToolHome(ToolLocationNodeProperty.java:107) at hudson.tools.ToolInstallation.translateFor(ToolInstallation.java:203) at hudson.model.JDK.forNode(JDK.java:122) at hudson.model.AbstractProject.getEnvironment(AbstractProject.java:311) at hudson.model.Run.getEnvironment(Run.java:1993) at hudson.model.AbstractBuild.getEnvironment(AbstractBuild.java:936) at hudson.maven.AbstractMavenBuild.getEnvironment(AbstractMavenBuild.java:59) at hudson.maven.MavenModuleSetBuild.getEnvironment(MavenModuleSetBuild.java:154) at hudson.tasks.ArtifactArchiver.perform(ArtifactArchiver.java:115) at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:19) at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:810) at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:785) at hudson.maven.MavenModuleSetBuild$MavenModuleSetBuildExecution.post2(MavenModuleSetBuild.java:946) at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:732) at hudson.model.Run.execute(Run.java:1568) at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:477) at hudson.model.ResourceController.execute(ResourceController.java:88) at hudson.model.Executor.run(Executor.java:236) Finished: FAILURE

    Jenkins JIRA | 4 years ago | First Last
    hudson.AbortException: Failed to install JDK. Exit code=2
  2. 0

    My steps: Base CentOS 6.0 AMI. > Install Java 7 via RPM as root. > Save as custom AMI. > Use new custom AMI for Jenkins slaves > Set up EC2 plugin as reflected in the attachment image. > Run a build, and get the following errors: Building remotely on i-0326a672 in workspace workspace/FriendList Installing tools/hudson.model.JDK/java7/jdk.sh [java7] $ tar xvzf tools/hudson.model.JDK/java7/jdk.sh tar (child): tools/hudson.model.JDK/java7/jdk.sh: Cannot open: No such file or directory tar (child): Error is not recoverable: exiting now tar: Child returned status 2 tar: Error is not recoverable: exiting now ERROR: Failed to install JDK. Exit code=2 Archiving artifacts Installing tools/hudson.model.JDK/java7/jdk.sh [java7] $ tar xvzf tools/hudson.model.JDK/java7/jdk.sh tar (child): tools/hudson.model.JDK/java7/jdk.sh: Cannot open: No such file or directory tar (child): Error is not recoverable: exiting now tar: Child returned status 2 tar: Error is not recoverable: exiting now ERROR: Failed to archive artifacts: target/*.jar hudson.AbortException: Failed to install JDK. Exit code=2 at hudson.tools.JDKInstaller.install(JDKInstaller.java:189) at hudson.tools.JDKInstaller.performInstallation(JDKInstaller.java:132) at hudson.tools.InstallerTranslator.getToolHome(InstallerTranslator.java:61) at hudson.tools.ToolLocationNodeProperty.getToolHome(ToolLocationNodeProperty.java:107) at hudson.tools.ToolInstallation.translateFor(ToolInstallation.java:203) at hudson.model.JDK.forNode(JDK.java:122) at hudson.model.AbstractProject.getEnvironment(AbstractProject.java:311) at hudson.model.Run.getEnvironment(Run.java:1993) at hudson.model.AbstractBuild.getEnvironment(AbstractBuild.java:936) at hudson.maven.AbstractMavenBuild.getEnvironment(AbstractMavenBuild.java:59) at hudson.maven.MavenModuleSetBuild.getEnvironment(MavenModuleSetBuild.java:154) at hudson.tasks.ArtifactArchiver.perform(ArtifactArchiver.java:115) at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:19) at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:810) at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:785) at hudson.maven.MavenModuleSetBuild$MavenModuleSetBuildExecution.post2(MavenModuleSetBuild.java:946) at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:732) at hudson.model.Run.execute(Run.java:1568) at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:477) at hudson.model.ResourceController.execute(ResourceController.java:88) at hudson.model.Executor.run(Executor.java:236) Finished: FAILURE

    Jenkins JIRA | 4 years ago | First Last
    hudson.AbortException: Failed to install JDK. Exit code=2

    Root Cause Analysis

    1. hudson.AbortException

      Failed to install JDK. Exit code=2

      at hudson.tools.JDKInstaller.install()
    2. Hudson
      AbstractBuild.getEnvironment
      1. hudson.tools.JDKInstaller.install(JDKInstaller.java:189)
      2. hudson.tools.JDKInstaller.performInstallation(JDKInstaller.java:132)
      3. hudson.tools.InstallerTranslator.getToolHome(InstallerTranslator.java:61)
      4. hudson.tools.ToolLocationNodeProperty.getToolHome(ToolLocationNodeProperty.java:107)
      5. hudson.tools.ToolInstallation.translateFor(ToolInstallation.java:203)
      6. hudson.model.JDK.forNode(JDK.java:122)
      7. hudson.model.AbstractProject.getEnvironment(AbstractProject.java:311)
      8. hudson.model.Run.getEnvironment(Run.java:1993)
      9. hudson.model.AbstractBuild.getEnvironment(AbstractBuild.java:936)
      9 frames
    3. Hudson Maven Embedder
      MavenModuleSetBuild.getEnvironment
      1. hudson.maven.AbstractMavenBuild.getEnvironment(AbstractMavenBuild.java:59)
      2. hudson.maven.MavenModuleSetBuild.getEnvironment(MavenModuleSetBuild.java:154)
      2 frames
    4. Hudson
      AbstractBuild$AbstractBuildExecution.performAllBuildSteps
      1. hudson.tasks.ArtifactArchiver.perform(ArtifactArchiver.java:115)
      2. hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:19)
      3. hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:810)
      4. hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:785)
      4 frames
    5. Hudson Maven Embedder
      MavenModuleSetBuild$MavenModuleSetBuildExecution.post2
      1. hudson.maven.MavenModuleSetBuild$MavenModuleSetBuildExecution.post2(MavenModuleSetBuild.java:946)
      1 frame
    6. Hudson
      Run.execute
      1. hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:732)
      2. hudson.model.Run.execute(Run.java:1568)
      2 frames
    7. Hudson Maven Embedder
      MavenModuleSetBuild.run
      1. hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:477)
      1 frame
    8. Hudson
      Executor.run
      1. hudson.model.ResourceController.execute(ResourceController.java:88)
      2. hudson.model.Executor.run(Executor.java:236)
      2 frames