com.atlassian.bamboo.task.TaskException: Failed to execute task

atlassian.com | 4 months ago
  1. 0

    Configuring the Docker task in Bamboo - Atlassian Documentation

    atlassian.com | 1 year ago
    com.atlassian.bamboo.task.TaskException: Failed to execute task
  2. 0

    Configuring the Docker task in Bamboo - Bamboo 5.8 - Atlassian Documentation

    atlassian.com | 4 months ago
    com.atlassian.bamboo.task.TaskException: Failed to execute task
  3. 0

    h3. Summary Non-detached Docker containers started from Bamboo are not stopped if build was cancelled manually. These containers will continue running and consume CPU on the host. h3. Steps to Reproduce # Configure build plan to start a Docker container # Start the build # When build is running, manually cancel the build using {{Actions >> Stop build}} h3. Expected Results The task should end gracefully by cleaning up the non detached docker containers it has spun up h3. Actual Results Docker containers started by the build will continue running in the background consuming CPU. The below exception is thrown in the atlassian-bamboo.log file: {noformat} 2016-05-11 13:27:34,864 INFO [13-BAM::Default Agent::Agent:pool-29-thread-1] [TaskResultBuilder] DOCK-TEST-JOB1-15: Failing task since return code of [/usr/local/bin/docker run --volume /Users/brosa/Documents/Atlassian/bamboo/bamboo-5.9.7/home/xml-data/build-dir/DOCK-TEST-JOB1:/data --workdir /data --rm brosadocker/customized-bamboo-java-agent:1.0.0] was 141 while expected 0 2016-05-11 13:27:34,865 INFO [13-BAM::Default Agent::Agent:pool-29-thread-1] [DefaultErrorHandler] Recording an error: Error occurred while running Task '(2)' of type com.atlassian.bamboo.plugins.bamboo-docker-plugin:task.docker.cli. : DOCK-TEST-JOB1 : Failed to execute task 2016-05-11 13:27:34,865 ERROR [13-BAM::Default Agent::Agent:pool-29-thread-1] [TaskExecutorImpl] Error occurred while running Task '(2)' of type com.atlassian.bamboo.plugins.bamboo-docker-plugin:task.docker.cli. com.atlassian.bamboo.task.TaskException: Failed to execute task at com.atlassian.bamboo.plugins.docker.service.RunService.execute(RunService.java:70) at com.atlassian.bamboo.plugins.docker.tasks.cli.DockerCliTask.execute(DockerCliTask.java:60) at com.atlassian.bamboo.task.TaskExecutorImpl$3.call(TaskExecutorImpl.java:288) at com.atlassian.bamboo.task.TaskExecutorImpl$3.call(TaskExecutorImpl.java:284) at com.atlassian.bamboo.task.TaskExecutorImpl.executeTaskWithPrePostActions(TaskExecutorImpl.java:200) at com.atlassian.bamboo.task.TaskExecutorImpl.executeTasks(TaskExecutorImpl.java:284) at com.atlassian.bamboo.task.TaskExecutorImpl.execute(TaskExecutorImpl.java:106) at com.atlassian.bamboo.build.pipeline.tasks.ExecuteBuildTask.call(ExecuteBuildTask.java:75) at com.atlassian.bamboo.v2.build.agent.DefaultBuildAgent.build(DefaultBuildAgent.java:196) at com.atlassian.bamboo.v2.build.agent.BuildAgentControllerImpl$1.call(BuildAgentControllerImpl.java:124) at com.atlassian.bamboo.v2.build.agent.BuildAgentControllerImpl$1.call(BuildAgentControllerImpl.java:115) at com.atlassian.bamboo.variable.CustomVariableContextImpl.withVariableSubstitutor(CustomVariableContextImpl.java:215) at com.atlassian.bamboo.v2.build.agent.BuildAgentControllerImpl.waitAndPerformBuild(BuildAgentControllerImpl.java:114) at com.atlassian.bamboo.v2.build.agent.DefaultBuildAgent$1.run(DefaultBuildAgent.java:118) at com.atlassian.bamboo.utils.BambooRunnables$1.run(BambooRunnables.java:49) at com.atlassian.bamboo.security.ImpersonationHelper.runWith(ImpersonationHelper.java:31) at com.atlassian.bamboo.security.ImpersonationHelper.runWithSystemAuthority(ImpersonationHelper.java:20) at com.atlassian.bamboo.security.ImpersonationHelper$1.run(ImpersonationHelper.java:52) at java.lang.Thread.run(Thread.java:745) Caused by: com.atlassian.bamboo.plugins.docker.client.DockerException: Error running Docker run command at com.atlassian.bamboo.plugins.docker.client.DockerCmd.run(DockerCmd.java:103) at com.atlassian.bamboo.plugins.docker.service.RunService.execute(RunService.java:59) ... 18 more Caused by: com.atlassian.utils.process.ProcessException: Error executing /usr/local/bin/docker run --volume /Users/brosa/Documents/Atlassian/bamboo/bamboo-5.9.7/home/xml-data/build-dir/DOCK-TEST-JOB1:/data --workdir /data --rm brosadocker/customized-bamboo-java-agent:1.0.0 at com.atlassian.bamboo.plugins.docker.process.DockerTaskProcessService.execute(DockerTaskProcessService.java:60) at com.atlassian.bamboo.plugins.docker.client.DockerCmd.run(DockerCmd.java:99) ... 19 more {noformat} h3.Workaround If a build was stopped manually, the docker containers will need to be stopped manually.

    Atlassian JIRA | 7 months ago | Deric Lee [Atlassian]
    com.atlassian.bamboo.task.TaskException: Failed to execute task
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    [PROTOCOL_ERROR] Received CHANNEL_SUCCESS on unknown channel - Atlassian Documentation

    atlassian.com | 4 months ago
    com.atlassian.bamboo.task.TaskException: SSH command failed
  6. 0

    h3. Summary Non-detached Docker containers started from Bamboo are not stopped if build was cancelled manually. These containers will continue running and consume CPU on the host. h3. Steps to Reproduce # Configure build plan to start a Docker container # Start the build # When build is running, manually cancel the build using {{Actions >> Stop build}} h3. Expected Results The task should end gracefully by cleaning up the non detached docker containers it has spun up h3. Actual Results Docker containers started by the build will continue running in the background consuming CPU. The below exception is thrown in the atlassian-bamboo.log file: {noformat} 2016-05-11 13:27:34,864 INFO [13-BAM::Default Agent::Agent:pool-29-thread-1] [TaskResultBuilder] DOCK-TEST-JOB1-15: Failing task since return code of [/usr/local/bin/docker run --volume /Users/brosa/Documents/Atlassian/bamboo/bamboo-5.9.7/home/xml-data/build-dir/DOCK-TEST-JOB1:/data --workdir /data --rm brosadocker/customized-bamboo-java-agent:1.0.0] was 141 while expected 0 2016-05-11 13:27:34,865 INFO [13-BAM::Default Agent::Agent:pool-29-thread-1] [DefaultErrorHandler] Recording an error: Error occurred while running Task '(2)' of type com.atlassian.bamboo.plugins.bamboo-docker-plugin:task.docker.cli. : DOCK-TEST-JOB1 : Failed to execute task 2016-05-11 13:27:34,865 ERROR [13-BAM::Default Agent::Agent:pool-29-thread-1] [TaskExecutorImpl] Error occurred while running Task '(2)' of type com.atlassian.bamboo.plugins.bamboo-docker-plugin:task.docker.cli. com.atlassian.bamboo.task.TaskException: Failed to execute task at com.atlassian.bamboo.plugins.docker.service.RunService.execute(RunService.java:70) at com.atlassian.bamboo.plugins.docker.tasks.cli.DockerCliTask.execute(DockerCliTask.java:60) at com.atlassian.bamboo.task.TaskExecutorImpl$3.call(TaskExecutorImpl.java:288) at com.atlassian.bamboo.task.TaskExecutorImpl$3.call(TaskExecutorImpl.java:284) at com.atlassian.bamboo.task.TaskExecutorImpl.executeTaskWithPrePostActions(TaskExecutorImpl.java:200) at com.atlassian.bamboo.task.TaskExecutorImpl.executeTasks(TaskExecutorImpl.java:284) at com.atlassian.bamboo.task.TaskExecutorImpl.execute(TaskExecutorImpl.java:106) at com.atlassian.bamboo.build.pipeline.tasks.ExecuteBuildTask.call(ExecuteBuildTask.java:75) at com.atlassian.bamboo.v2.build.agent.DefaultBuildAgent.build(DefaultBuildAgent.java:196) at com.atlassian.bamboo.v2.build.agent.BuildAgentControllerImpl$1.call(BuildAgentControllerImpl.java:124) at com.atlassian.bamboo.v2.build.agent.BuildAgentControllerImpl$1.call(BuildAgentControllerImpl.java:115) at com.atlassian.bamboo.variable.CustomVariableContextImpl.withVariableSubstitutor(CustomVariableContextImpl.java:215) at com.atlassian.bamboo.v2.build.agent.BuildAgentControllerImpl.waitAndPerformBuild(BuildAgentControllerImpl.java:114) at com.atlassian.bamboo.v2.build.agent.DefaultBuildAgent$1.run(DefaultBuildAgent.java:118) at com.atlassian.bamboo.utils.BambooRunnables$1.run(BambooRunnables.java:49) at com.atlassian.bamboo.security.ImpersonationHelper.runWith(ImpersonationHelper.java:31) at com.atlassian.bamboo.security.ImpersonationHelper.runWithSystemAuthority(ImpersonationHelper.java:20) at com.atlassian.bamboo.security.ImpersonationHelper$1.run(ImpersonationHelper.java:52) at java.lang.Thread.run(Thread.java:745) Caused by: com.atlassian.bamboo.plugins.docker.client.DockerException: Error running Docker run command at com.atlassian.bamboo.plugins.docker.client.DockerCmd.run(DockerCmd.java:103) at com.atlassian.bamboo.plugins.docker.service.RunService.execute(RunService.java:59) ... 18 more Caused by: com.atlassian.utils.process.ProcessException: Error executing /usr/local/bin/docker run --volume /Users/brosa/Documents/Atlassian/bamboo/bamboo-5.9.7/home/xml-data/build-dir/DOCK-TEST-JOB1:/data --workdir /data --rm brosadocker/customized-bamboo-java-agent:1.0.0 at com.atlassian.bamboo.plugins.docker.process.DockerTaskProcessService.execute(DockerTaskProcessService.java:60) at com.atlassian.bamboo.plugins.docker.client.DockerCmd.run(DockerCmd.java:99) ... 19 more {noformat} h3.Workaround If a build was stopped manually, the docker containers will need to be stopped manually.

    Atlassian JIRA | 7 months ago | Deric Lee
    com.atlassian.bamboo.task.TaskException: Failed to execute task

    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. com.atlassian.utils.process.ProcessException

      Error executing /usr/bin/docker build --no-cache=true --tag="docker.atlassian.io/dk:9.3" /home/bamboo/bamboo-agent-home/xml-data/build-dir/DDT-REP-JOB1

      at com.atlassian.bamboo.plugins.docker.process.DockerTaskProcessService.execute()
    2. com.atlassian.bamboo
      ImpersonationHelper$1.run
      1. com.atlassian.bamboo.plugins.docker.process.DockerTaskProcessService.execute(DockerTaskProcessService.java:57)
      2. com.atlassian.bamboo.plugins.docker.client.DockerCmd.build(DockerCmd.java:145)
      3. com.atlassian.bamboo.plugins.docker.service.BuildService.execute(BuildService.java:40)
      4. com.atlassian.bamboo.plugins.docker.tasks.cli.DockerCliTask.execute(DockerCliTask.java:60)
      5. com.atlassian.bamboo.task.TaskExecutorImpl$3.call(TaskExecutorImpl.java:281)
      6. com.atlassian.bamboo.task.TaskExecutorImpl$3.call(TaskExecutorImpl.java:278)
      7. com.atlassian.bamboo.task.TaskExecutorImpl.executeTaskWithPrePostActions(TaskExecutorImpl.java:198)
      8. com.atlassian.bamboo.task.TaskExecutorImpl.executeTasks(TaskExecutorImpl.java:278)
      9. com.atlassian.bamboo.task.TaskExecutorImpl.execute(TaskExecutorImpl.java:105)
      10. com.atlassian.bamboo.build.pipeline.tasks.ExecuteBuildTask.call(ExecuteBuildTask.java:75)
      11. com.atlassian.bamboo.v2.build.agent.DefaultBuildAgent.build(DefaultBuildAgent.java:188)
      12. com.atlassian.bamboo.v2.build.agent.BuildAgentControllerImpl.waitAndPerformBuild(BuildAgentControllerImpl.java:112)
      13. com.atlassian.bamboo.v2.build.agent.DefaultBuildAgent$1.run(DefaultBuildAgent.java:110)
      14. com.atlassian.bamboo.utils.BambooRunnables$1.run(BambooRunnables.java:49)
      15. com.atlassian.bamboo.security.ImpersonationHelper.runWith(ImpersonationHelper.java:31)
      16. com.atlassian.bamboo.security.ImpersonationHelper.runWithSystemAuthority(ImpersonationHelper.java:20)
      17. com.atlassian.bamboo.security.ImpersonationHelper$1.run(ImpersonationHelper.java:52)
      17 frames
    3. Java RT
      Thread.run
      1. java.lang.Thread.run(Thread.java:745)
      1 frame