Hi, I am trying to setting up Bamboo 5.2 to be able to compile some software on a windows 7 remote agent. The git repository that we're using is Atlassian Stash. I have installed msysGit on the remote agent, and I am able to clone the repository manually using the command line or Tortoise Git. However, I am not able to perform the Source Code checkout step of a job, it fails with the following message :
Here is the full output message :
simple 09-Dec-2013 14:23:25 Build MPM 2.X - Packager - Compilation_IAR #26 (MPM2X-PAC-COM-26) started building on agent Emb-Packager simple 09-Dec-2013 14:23:26 Build working directory is C:\Users\free2\bamboo-agent-home\xml-data\build-dir\MPM2X-PAC-COM simple 09-Dec-2013 14:23:26 Executing build MPM 2.X - Packager - Compilation_IAR #26 (MPM2X-PAC-COM-26) simple 09-Dec-2013 14:23:26 Starting task 'Checkout Packager Repository' of type 'com.atlassian.bamboo.plugins.vcs:task.vcs.checkout' simple 09-Dec-2013 14:23:26 Build always requires a clean checkout simple 09-Dec-2013 14:23:26 Cleaning build directory 'C:\Users\free2\bamboo-agent-home\xml-data\build-dir\MPM2X-PAC-COM\emb\packager' simple 09-Dec-2013 14:23:26 Updating source code to revision: 43bc8fc3837b6f7333cfc46a33abf55c38407fce error 09-Dec-2013 14:23:27 Cannot fetch branch '(unresolved) master' from 'ssh://git@'server'/packager.git' to source directory 'C:\Users\free2\bamboo-agent-home\xml-data\build-dir\_git-repositories-cache\79e3c4ed078d4e2a40996a5d43169955766a1736'. com.atlassian.bamboo.plugins.git.GitCommandException: command C:\Git\cmd\git.exe ls-remote ssh://8ceb269a-bb09-4bfe-b824-8940d67a7a70@127.0.0.1:1095/mpm2x/packager.git failed with code 128. Working directory was [C:\Users\free2\bamboo-agent-home\xml-data\build-dir\_git-repositories-cache\79e3c4ed078d4e2a40996a5d43169955766a1736]., stderr:[error: cannot spawn C:\Windows\system32\config\systemprofile\AppData\Local\Temp\bamboo-ssh.41538fd5.bat: No such file or directory, fatal: unable to fork] simple 09-Dec-2013 14:23:27 Warning: failed to retrieve source code to cache directory 'C:\Users\free2\bamboo-agent-home\xml-data\build-dir\_git-repositories-cache\79e3c4ed078d4e2a40996a5d43169955766a1736', trying to recover... simple 09-Dec-2013 14:23:27 Cleaned cache directory 'C:\Users\free2\bamboo-agent-home\xml-data\build-dir\_git-repositories-cache\79e3c4ed078d4e2a40996a5d43169955766a1736', trying to fetch the code once again... simple 09-Dec-2013 14:23:27 Creating local git repository in 'C:\Users\free2\bamboo-agent-home\xml-data\build-dir\_git-repositories-cache\79e3c4ed078d4e2a40996a5d43169955766a1736\.git'. simple 09-Dec-2013 14:23:27 Initialized empty Git repository in C:/Users/free2/bamboo-agent-home/xml-data/build-dir/_git-repositories-cache/79e3c4ed078d4e2a40996a5d43169955766a1736/.git/ error 09-Dec-2013 14:23:27 Cannot fetch branch '(unresolved) master' from 'ssh://git@'server'/packager.git' to source directory 'C:\Users\free2\bamboo-agent-home\xml-data\build-dir\_git-repositories-cache\79e3c4ed078d4e2a40996a5d43169955766a1736'. com.atlassian.bamboo.plugins.git.GitCommandException: command C:\Git\cmd\git.exe ls-remote ssh://f25b5f39-7956-419a-9839-9ba42e3d6ec8@127.0.0.1:1095/mpm2x/packager.git failed with code 128. Working directory was [C:\Users\free2\bamboo-agent-home\xml-data\build-dir\_git-repositories-cache\79e3c4ed078d4e2a40996a5d43169955766a1736]., stderr:[error: cannot spawn C:\Windows\system32\config\systemprofile\AppData\Local\Temp\bamboo-ssh.41538fd5.bat: No such file or directory, fatal: unable to fork] simple 09-Dec-2013 14:23:27 Updating source code to revision: 43bc8fc3837b6f7333cfc46a33abf55c38407fce error 09-Dec-2013 14:23:27 Cannot fetch branch '(unresolved) master' from 'ssh://git@'server'/packager.git' to source directory 'C:\Users\free2\bamboo-agent-home\xml-data\build-dir\_git-repositories-cache\79e3c4ed078d4e2a40996a5d43169955766a1736'. com.atlassian.bamboo.plugins.git.GitCommandException: command C:\Git\cmd\git.exe ls-remote ssh://235d3913-5d49-4540-9f44-1a3c56518e77@127.0.0.1:1095/mpm2x/packager.git failed with code 128. Working directory was [C:\Users\free2\bamboo-agent-home\xml-data\build-dir\_git-repositories-cache\79e3c4ed078d4e2a40996a5d43169955766a1736]., stderr:[error: cannot spawn C:\Windows\system32\config\systemprofile\AppData\Local\Temp\bamboo-ssh.41538fd5.bat: No such file or directory, fatal: unable to fork] simple 09-Dec-2013 14:23:27 Warning: failed to retrieve source code to cache directory 'C:\Users\free2\bamboo-agent-home\xml-data\build-dir\_git-repositories-cache\79e3c4ed078d4e2a40996a5d43169955766a1736', trying to recover... simple 09-Dec-2013 14:23:27 Cleaned cache directory 'C:\Users\free2\bamboo-agent-home\xml-data\build-dir\_git-repositories-cache\79e3c4ed078d4e2a40996a5d43169955766a1736', trying to fetch the code once again... simple 09-Dec-2013 14:23:27 Creating local git repository in 'C:\Users\free2\bamboo-agent-home\xml-data\build-dir\_git-repositories-cache\79e3c4ed078d4e2a40996a5d43169955766a1736\.git'. simple 09-Dec-2013 14:23:28 Initialized empty Git repository in C:/Users/free2/bamboo-agent-home/xml-data/build-dir/_git-repositories-cache/79e3c4ed078d4e2a40996a5d43169955766a1736/.git/ error 09-Dec-2013 14:23:28 Cannot fetch branch '(unresolved) master' from 'ssh://git@'server'/packager.git' to source directory 'C:\Users\free2\bamboo-agent-home\xml-data\build-dir\_git-repositories-cache\79e3c4ed078d4e2a40996a5d43169955766a1736'. com.atlassian.bamboo.plugins.git.GitCommandException: command C:\Git\cmd\git.exe ls-remote ssh://3a5dbb10-cef9-47d5-b78f-feb0bfe9e27d@127.0.0.1:1095/mpm2x/packager.git failed with code 128. Working directory was [C:\Users\free2\bamboo-agent-home\xml-data\build-dir\_git-repositories-cache\79e3c4ed078d4e2a40996a5d43169955766a1736]., stderr:[error: cannot spawn C:\Windows\system32\config\systemprofile\AppData\Local\Temp\bamboo-ssh.41538fd5.bat: No such file or directory, fatal: unable to fork] simple 09-Dec-2013 14:23:29 Updating source code to revision: 43bc8fc3837b6f7333cfc46a33abf55c38407fce error 09-Dec-2013 14:23:29 Cannot fetch branch '(unresolved) master' from 'ssh://git@'server'/packager.git' to source directory 'C:\Users\free2\bamboo-agent-home\xml-data\build-dir\_git-repositories-cache\79e3c4ed078d4e2a40996a5d43169955766a1736'. com.atlassian.bamboo.plugins.git.GitCommandException: command C:\Git\cmd\git.exe ls-remote ssh://11038838-0e2c-4564-8801-87dad461d1bd@127.0.0.1:1095/mpm2x/packager.git failed with code 128. Working directory was [C:\Users\free2\bamboo-agent-home\xml-data\build-dir\_git-repositories-cache\79e3c4ed078d4e2a40996a5d43169955766a1736]., stderr:[error: cannot spawn C:\Windows\system32\config\systemprofile\AppData\Local\Temp\bamboo-ssh.41538fd5.bat: No such file or directory, fatal: unable to fork] simple 09-Dec-2013 14:23:29 Warning: failed to retrieve source code to cache directory 'C:\Users\free2\bamboo-agent-home\xml-data\build-dir\_git-repositories-cache\79e3c4ed078d4e2a40996a5d43169955766a1736', trying to recover... simple 09-Dec-2013 14:23:29 Cleaned cache directory 'C:\Users\free2\bamboo-agent-home\xml-data\build-dir\_git-repositories-cache\79e3c4ed078d4e2a40996a5d43169955766a1736', trying to fetch the code once again... simple 09-Dec-2013 14:23:29 Creating local git repository in 'C:\Users\free2\bamboo-agent-home\xml-data\build-dir\_git-repositories-cache\79e3c4ed078d4e2a40996a5d43169955766a1736\.git'. simple 09-Dec-2013 14:23:29 Initialized empty Git repository in C:/Users/free2/bamboo-agent-home/xml-data/build-dir/_git-repositories-cache/79e3c4ed078d4e2a40996a5d43169955766a1736/.git/ error 09-Dec-2013 14:23:29 Cannot fetch branch '(unresolved) master' from 'ssh://git@'server'/packager.git' to source directory 'C:\Users\free2\bamboo-agent-home\xml-data\build-dir\_git-repositories-cache\79e3c4ed078d4e2a40996a5d43169955766a1736'. com.atlassian.bamboo.plugins.git.GitCommandException: command C:\Git\cmd\git.exe ls-remote ssh://f8ff0cd5-0cb5-4788-bf4b-bed1b5a6da09@127.0.0.1:1095/mpm2x/packager.git failed with code 128. Working directory was [C:\Users\free2\bamboo-agent-home\xml-data\build-dir\_git-repositories-cache\79e3c4ed078d4e2a40996a5d43169955766a1736]., stderr:[error: cannot spawn C:\Windows\system32\config\systemprofile\AppData\Local\Temp\bamboo-ssh.41538fd5.bat: No such file or directory, fatal: unable to fork] error 09-Dec-2013 14:23:29 Error occurred while running Task 'Checkout Packager Repository(1)' of type com.atlassian.bamboo.plugins.vcs:task.vcs.checkout. error 09-Dec-2013 14:23:29 java.lang.RuntimeException: com.atlassian.bamboo.repository.RepositoryException: Cannot fetch branch '(unresolved) master' from 'ssh://git@'server'/packager.git' to source directory 'C:\Users\free2\bamboo-agent-home\xml-data\build-dir\_git-repositories-cache\79e3c4ed078d4e2a40996a5d43169955766a1736'. com.atlassian.bamboo.plugins.git.GitCommandException: command C:\Git\cmd\git.exe ls-remote ssh://f8ff0cd5-0cb5-4788-bf4b-bed1b5a6da09@127.0.0.1:1095/mpm2x/packager.git failed with code 128. Working directory was [C:\Users\free2\bamboo-agent-home\xml-data\build-dir\_git-repositories-cache\79e3c4ed078d4e2a40996a5d43169955766a1736]., stderr: error 09-Dec-2013 14:23:29 [error: cannot spawn C:\Windows\system32\config\systemprofile\AppData\Local\Temp\bamboo-ssh.41538fd5.bat: No such file or directory, fatal: unable to fork] error 09-Dec-2013 14:23:29 at com.atlassian.bamboo.executor.RetryingTaskExecutor.rerun(RetryingTaskExecutor.java:132) error 09-Dec-2013 14:23:29 at com.atlassian.bamboo.executor.RetryingTaskExecutor.runTask(RetryingTaskExecutor.java:88) error 09-Dec-2013 14:23:29 at com.atlassian.bamboo.executor.RetryingTaskExecutor.retry(RetryingTaskExecutor.java:191) error 09-Dec-2013 14:23:29 at com.atlassian.bamboo.executor.RetryingTaskExecutor.retry(RetryingTaskExecutor.java:176) error 09-Dec-2013 14:23:29 at com.atlassian.bamboo.plugins.vcs.task.VcsCheckoutTask.execute(VcsCheckoutTask.java:170) error 09-Dec-2013 14:23:29 at com.atlassian.bamboo.task.TaskExecutorImpl.executeTasks(TaskExecutorImpl.java:220) error 09-Dec-2013 14:23:29 at com.atlassian.bamboo.task.TaskExecutorImpl.executePreparationTasks(TaskExecutorImpl.java:73) error 09-Dec-2013 14:23:29 at com.atlassian.bamboo.build.pipeline.tasks.PrepareBuildTask.call(PrepareBuildTask.java:74) error 09-Dec-2013 14:23:29 at com.atlassian.bamboo.v2.build.agent.DefaultBuildAgent.build(DefaultBuildAgent.java:181) error 09-Dec-2013 14:23:29 at com.atlassian.bamboo.v2.build.agent.BuildAgentControllerImpl.waitAndPerformBuild(BuildAgentControllerImpl.java:101) error 09-Dec-2013 14:23:29 at com.atlassian.bamboo.v2.build.agent.DefaultBuildAgent$1.run(DefaultBuildAgent.java:108) error 09-Dec-2013 14:23:29 at com.atlassian.bamboo.build.pipeline.concurrent.NamedThreadFactory$2.run(NamedThreadFactory.java:55) error 09-Dec-2013 14:23:29 at java.lang.Thread.run(Unknown Source) error 09-Dec-2013 14:23:29 Caused by: com.atlassian.bamboo.repository.RepositoryException: Cannot fetch branch '(unresolved) master' from 'ssh://git@'server'/packager.git' to source directory 'C:\Users\free2\bamboo-agent-home\xml-data\build-dir\_git-repositories-cache\79e3c4ed078d4e2a40996a5d43169955766a1736'. com.atlassian.bamboo.plugins.git.GitCommandException: command C:\Git\cmd\git.exe ls-remote ssh://f8ff0cd5-0cb5-4788-bf4b-bed1b5a6da09@127.0.0.1:1095/mpm2x/packager.git failed with code 128. Working directory was [C:\Users\free2\bamboo-agent-home\xml-data\build-dir\_git-repositories-cache\79e3c4ed078d4e2a40996a5d43169955766a1736]., stderr: error 09-Dec-2013 14:23:29 [error: cannot spawn C:\Windows\system32\config\systemprofile\AppData\Local\Temp\bamboo-ssh.41538fd5.bat: No such file or directory, fatal: unable to fork] error 09-Dec-2013 14:23:29 at com.atlassian.bamboo.plugins.git.NativeGitOperationHelper.fetch(NativeGitOperationHelper.java:388) error 09-Dec-2013 14:23:29 at com.atlassian.bamboo.plugins.git.GitRepository$3.call(GitRepository.java:347) error 09-Dec-2013 14:23:29 at com.atlassian.bamboo.plugins.git.GitRepository$3.call(GitRepository.java:335) error 09-Dec-2013 14:23:29 at com.atlassian.util.concurrent.ManagedLocks$ManagedLockImpl.withLock(ManagedLocks.java:312) error 09-Dec-2013 14:23:29 at com.atlassian.bamboo.plugins.git.GitRepository.retrieveSourceCode(GitRepository.java:334) error 09-Dec-2013 14:23:29 at com.atlassian.bamboo.plugins.git.GitRepository.retrieveSourceCode(GitRepository.java:310) error 09-Dec-2013 14:23:29 at com.atlassian.bamboo.plugins.vcs.task.VcsCheckoutTask.fillWorkingDirFromVcs(VcsCheckoutTask.java:248) error 09-Dec-2013 14:23:29 at com.atlassian.bamboo.plugins.vcs.task.VcsCheckoutTask.access$100(VcsCheckoutTask.java:54) error 09-Dec-2013 14:23:29 at com.atlassian.bamboo.plugins.vcs.task.VcsCheckoutTask$2.call(VcsCheckoutTask.java:175) error 09-Dec-2013 14:23:29 at com.atlassian.bamboo.plugins.vcs.task.VcsCheckoutTask$2.call(VcsCheckoutTask.java:171) error 09-Dec-2013 14:23:29 at com.atlassian.bamboo.executor.RetryingTaskExecutor.rerun(RetryingTaskExecutor.java:108) error 09-Dec-2013 14:23:29 ... 12 more error 09-Dec-2013 14:23:29 Caused by: com.google.common.util.concurrent.UncheckedExecutionException: com.atlassian.bamboo.plugins.git.GitCommandException: command C:\Git\cmd\git.exe ls-remote ssh://f8ff0cd5-0cb5-4788-bf4b-bed1b5a6da09@127.0.0.1:1095/mpm2x/packager.git failed with code 128. Working directory was [C:\Users\free2\bamboo-agent-home\xml-data\build-dir\_git-repositories-cache\79e3c4ed078d4e2a40996a5d43169955766a1736]., stderr: error 09-Dec-2013 14:23:29 [error: cannot spawn C:\Windows\system32\config\systemprofile\AppData\Local\Temp\bamboo-ssh.41538fd5.bat: No such file or directory, fatal: unable to fork] error 09-Dec-2013 14:23:29 at com.google.common.cache.AbstractCache.getUnchecked(AbstractCache.java:51) error 09-Dec-2013 14:23:29 at com.atlassian.bamboo.util.CallableResultCache.call(CallableResultCache.java:82) error 09-Dec-2013 14:23:29 at com.atlassian.bamboo.plugins.git.NativeGitOperationHelper.getRemoteRefs(NativeGitOperationHelper.java:463) error 09-Dec-2013 14:23:29 at com.atlassian.bamboo.plugins.git.NativeGitOperationHelper.resolveBranch(NativeGitOperationHelper.java:398) error 09-Dec-2013 14:23:29 at com.atlassian.bamboo.plugins.git.NativeGitOperationHelper.fetch(NativeGitOperationHelper.java:363) error 09-Dec-2013 14:23:29 ... 22 more error 09-Dec-2013 14:23:29 Caused by: com.atlassian.bamboo.plugins.git.GitCommandException: command C:\Git\cmd\git.exe ls-remote ssh://f8ff0cd5-0cb5-4788-bf4b-bed1b5a6da09@127.0.0.1:1095/mpm2x/packager.git failed with code 128. Working directory was [C:\Users\free2\bamboo-agent-home\xml-data\build-dir\_git-repositories-cache\79e3c4ed078d4e2a40996a5d43169955766a1736]., stderr: error 09-Dec-2013 14:23:29 [error: cannot spawn C:\Windows\system32\config\systemprofile\AppData\Local\Temp\bamboo-ssh.41538fd5.bat: No such file or directory, fatal: unable to fork] error 09-Dec-2013 14:23:29 at com.atlassian.bamboo.plugins.git.GitCommandProcessor.runCommand(GitCommandProcessor.java:496) error 09-Dec-2013 14:23:29 at com.atlassian.bamboo.plugins.git.GitCommandProcessor.getRemoteRefs(GitCommandProcessor.java:416) error 09-Dec-2013 14:23:29 at com.atlassian.bamboo.plugins.git.NativeGitOperationHelper$1.call(NativeGitOperationHelper.java:451) error 09-Dec-2013 14:23:29 at com.atlassian.bamboo.plugins.git.NativeGitOperationHelper$1.call(NativeGitOperationHelper.java:442) error 09-Dec-2013 14:23:29 at com.atlassian.bamboo.util.CallableResultCache$1.load(CallableResultCache.java:29) error 09-Dec-2013 14:23:29 at com.atlassian.bamboo.util.CallableResultCache$1.load(CallableResultCache.java:25) error 09-Dec-2013 14:23:29 at com.google.common.cache.CustomConcurrentHashMap$ComputingValueReference.compute(CustomConcurrentHashMap.java:3426) error 09-Dec-2013 14:23:29 at com.google.common.cache.CustomConcurrentHashMap$Segment.compute(CustomConcurrentHashMap.java:2322) error 09-Dec-2013 14:23:29 at com.google.common.cache.CustomConcurrentHashMap$Segment.getOrCompute(CustomConcurrentHashMap.java:2291) error 09-Dec-2013 14:23:29 at com.google.common.cache.CustomConcurrentHashMap.getOrCompute(CustomConcurrentHashMap.java:3802) error 09-Dec-2013 14:23:29 at com.google.common.cache.ComputingCache.get(ComputingCache.java:46) error 09-Dec-2013 14:23:29 at com.google.common.cache.AbstractCache.getUnchecked(AbstractCache.java:49) error 09-Dec-2013 14:23:29 ... 26 more error 09-Dec-2013 14:23:29 Caused by: com.atlassian.utils.process.ProcessException: Non-zero exit code: 128 error 09-Dec-2013 14:23:29 at com.atlassian.utils.process.PluggableProcessHandler.complete(PluggableProcessHandler.java:69) error 09-Dec-2013 14:23:29 at com.atlassian.utils.process.ExternalProcessImpl.wrapUpProcess(ExternalProcessImpl.java:541) error 09-Dec-2013 14:23:29 at com.atlassian.utils.process.ExternalProcessImpl.finish(ExternalProcessImpl.java:455) error 09-Dec-2013 14:23:29 at com.atlassian.utils.process.ExternalProcessImpl.execute(ExternalProcessImpl.java:410) error 09-Dec-2013 14:23:29 at com.atlassian.bamboo.plugins.git.GitCommandProcessor.runCommand(GitCommandProcessor.java:488) error 09-Dec-2013 14:23:29 ... 37 more error 09-Dec-2013 14:23:29 Failed to prepare the build 'MPM 2.X - Packager - Compilation_IAR #26 (MPM2X-PAC-COM-26)' simple 09-Dec-2013 14:23:29 Running on server: post build plugin 'NCover Results Collector' simple 09-Dec-2013 14:23:29 Running on server: post build plugin 'Clover Delta Calculator' simple 09-Dec-2013 14:23:29 Running on server: post build plugin 'Build Hanging Detection Configuration' simple 09-Dec-2013 14:23:29 Running on server: post build plugin 'Maven Dependencies Postprocessor' simple 09-Dec-2013 14:23:29 All post build plugins have finished simple 09-Dec-2013 14:23:29 Generating build results summary... simple 09-Dec-2013 14:23:29 Saving build results to disk... simple 09-Dec-2013 14:23:29 Indexing build results... simple 09-Dec-2013 14:23:29 Finished building MPM2X-PAC-COM-26.
I have tried changing the value of the GIT_SSH environment variable in windows, and set it to C:\Git\bin\ssh.exe, and moved all the git stuff over there, but to no avail, It always fails with the above error message.
The error always seems to be this one :
error: cannot spawn C:\Windows\system32\config\systemprofile\AppData\Local\Temp\bamboo-ssh.41538fd5.bat: No such file or directory, fatal: unable to fork]
However, I can see clearly that the file exists and that I can open it and read its contents.
By the way, the Bamboo Remote Agent is installed as a service on this machine, if it makes a difference.
If possible, I would like to find the root cause of this issue. I cannot possibly be the only person having this issue with Bamboo and Windows ?
Also, I wanted to mention that we also have some Remote Agents running on Linux. In order to troubleshoot this issue, I have ran a test task to checkout the source code from the same Stash repository, and this works every time. This problem really seems to be windows- related...
Best Regards,
|
||||||||||||||||||||
|
Changing my temp dir as suggested above fixed my problem!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I was experiencing the same error. My remote agent's home directory was in a custom location (configured in wrapper) but it did not have it's temp directory configured. I followed the instructions above and this corrected my issue. Thank you.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Amir,
I'm told you might want to configure your temp directory to something outside of system32 by modifying the wrapper.conf.
If you get stuck I might suggest raise a support ticket so we help you further.
Cheers,
Charles
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi I am getting the same problem. Can't seem to determine the solution from this thread...
What is the solution?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Thank you for your quick response. I tried editing the wrapper.conf file as suggested in your link, but I`m still getting the same error.
I will take your advice and open a ticket.
Regards,
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.