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

Jenkins JIRA | First Last | 4 years ago
  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
  3. 0

    Problem with downloading html oracle sdk - instead of ask on credential occur again - now for java 8. Started by user anonymous Building in workspace /var/lib/jenkins/jobs/redmineplay/workspace Installing JDK jdk-8-oth-JPR Downloading JDK from http://download.oracle.com/otn-pub/java/jdk/8-b132/jdk-8-linux-x64.tar.gz Downloading 5307bytes Installing /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh [JDK] $ /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh -noregister /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 1: html: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 2: head: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 3: title: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 4: META: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 5: link: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 6: link: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 7: : command not found /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 8: body: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 9: div: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 10: table: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 11: tr: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 12: syntax error near unexpected token `<' /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 12: ` <td rowspan="2" valign="middle" nowrap><a href="http://www.oracle.com"><img src="/errors/us/assets/oralogo-small.gif" width="154" height="19" hspace="10" vspace="25" border="0" ></a></td> ' ERROR: Failed to install JDK. Exit code=2 Archiving artifacts Installing JDK jdk-8-oth-JPR Downloading JDK from http://download.oracle.com/otn-pub/java/jdk/8-b132/jdk-8-linux-x64.tar.gz Downloading 5307bytes Installing /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh [JDK] $ /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh -noregister /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 1: html: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 2: head: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 3: title: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 4: META: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 5: link: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 6: link: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 7: : command not found /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 8: body: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 9: div: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 10: table: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 11: tr: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 12: syntax error near unexpected token `<' /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 12: ` <td rowspan="2" valign="middle" nowrap><a href="http://www.oracle.com"><img src="/errors/us/assets/oralogo-small.gif" width="154" height="19" hspace="10" vspace="25" border="0" ></a></td> ' ERROR: Failed to archive artifacts: smtpserver/target/*.tar.gz 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:204) at hudson.model.JDK.forNode(JDK.java:126) at hudson.model.AbstractProject.getEnvironment(AbstractProject.java:352) at hudson.model.Run.getEnvironment(Run.java:2196) at hudson.model.AbstractBuild.getEnvironment(AbstractBuild.java:871) at hudson.tasks.ArtifactArchiver.perform(ArtifactArchiver.java:136) at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20) at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:742) at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:714) at hudson.model.Build$BuildExecution.post2(Build.java:183) at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:663) at hudson.model.Run.execute(Run.java:1713) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43) at hudson.model.ResourceController.execute(ResourceController.java:88) at hudson.model.Executor.run(Executor.java:231) Finished: FAILURE

    Jenkins JIRA | 3 years ago | Andrzej Jóźwik
    hudson.AbortException: Failed to install JDK. Exit code=2
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    Problem with downloading html oracle sdk - instead of ask on credential occur again - now for java 8. Started by user anonymous Building in workspace /var/lib/jenkins/jobs/redmineplay/workspace Installing JDK jdk-8-oth-JPR Downloading JDK from http://download.oracle.com/otn-pub/java/jdk/8-b132/jdk-8-linux-x64.tar.gz Downloading 5307bytes Installing /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh [JDK] $ /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh -noregister /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 1: html: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 2: head: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 3: title: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 4: META: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 5: link: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 6: link: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 7: : command not found /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 8: body: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 9: div: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 10: table: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 11: tr: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 12: syntax error near unexpected token `<' /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 12: ` <td rowspan="2" valign="middle" nowrap><a href="http://www.oracle.com"><img src="/errors/us/assets/oralogo-small.gif" width="154" height="19" hspace="10" vspace="25" border="0" ></a></td> ' ERROR: Failed to install JDK. Exit code=2 Archiving artifacts Installing JDK jdk-8-oth-JPR Downloading JDK from http://download.oracle.com/otn-pub/java/jdk/8-b132/jdk-8-linux-x64.tar.gz Downloading 5307bytes Installing /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh [JDK] $ /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh -noregister /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 1: html: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 2: head: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 3: title: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 4: META: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 5: link: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 6: link: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 7: : command not found /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 8: body: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 9: div: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 10: table: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 11: tr: No such file or directory /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 12: syntax error near unexpected token `<' /var/lib/jenkins/tools/hudson.model.JDK/JDK/jdk.sh: line 12: ` <td rowspan="2" valign="middle" nowrap><a href="http://www.oracle.com"><img src="/errors/us/assets/oralogo-small.gif" width="154" height="19" hspace="10" vspace="25" border="0" ></a></td> ' ERROR: Failed to archive artifacts: smtpserver/target/*.tar.gz 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:204) at hudson.model.JDK.forNode(JDK.java:126) at hudson.model.AbstractProject.getEnvironment(AbstractProject.java:352) at hudson.model.Run.getEnvironment(Run.java:2196) at hudson.model.AbstractBuild.getEnvironment(AbstractBuild.java:871) at hudson.tasks.ArtifactArchiver.perform(ArtifactArchiver.java:136) at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20) at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:742) at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:714) at hudson.model.Build$BuildExecution.post2(Build.java:183) at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:663) at hudson.model.Run.execute(Run.java:1713) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43) at hudson.model.ResourceController.execute(ResourceController.java:88) at hudson.model.Executor.run(Executor.java:231) Finished: FAILURE

    Jenkins JIRA | 3 years ago | Andrzej Jóźwik
    hudson.AbortException: Failed to install JDK. Exit code=2
  6. 0

    It seems Oracle is blocking access to older JDKs without login from the URL in the stacktrace. Possible solutions: - change url to http://www.oracle.com/technetwork/java/javase/downloads/jdk7u9-downloads-1859576.html as it currently does not require login - provide username/password support for oracle accounts. - update the list to support auto install for JDK 7 u10 {code} Installing JDK jdk-7u9-oth-JPR Downloading JDK from http://download.oracle.com/otn/java/jdk/7u9-b05/jdk-7u9-linux-x64.tar.gz Your Oracle account doesn't appear valid. Please specify a valid username/password ERROR: Unable to install JDK unless a valid username/password is provided. Skipping Cobertura coverage report as build was not UNSTABLE or better ... Installing JDK jdk-7u9-oth-JPR Downloading JDK from http://download.oracle.com/otn/java/jdk/7u9-b05/jdk-7u9-linux-x64.tar.gz Your Oracle account doesn't appear valid. Please specify a valid username/password ERROR: Publisher hudson.tasks.Mailer aborted due to exception hudson.AbortException: Unable to install JDK unless a valid username/password is provided. at hudson.tools.JDKInstaller.locate(JDKInstaller.java:421) at hudson.tools.JDKInstaller.performInstallation(JDKInstaller.java:125) 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:310) at hudson.model.Run.getEnvironment(Run.java:1967) at hudson.model.AbstractBuild.getEnvironment(AbstractBuild.java:930) at hudson.tasks.Mailer.perform(Mailer.java:112) at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:19) at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:804) at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:779) at hudson.model.Build$BuildExecution.post2(Build.java:183) at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:726) at hudson.model.Run.execute(Run.java:1543) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46) at hudson.model.ResourceController.execute(ResourceController.java:88) at hudson.model.Executor.run(Executor.java:236) Finished: FAILURE {code}

    Jenkins JIRA | 4 years ago | Thomas Neumeier
    hudson.AbortException: Unable to install JDK unless a valid username/password is provided.

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    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