|
I am currently having the same issue on a Windows Master, Ubuntu Slave Jenkins ver. 1.626
The default git is C:\Cygin64\bin\git.exe, which works on the windows master.
A second definition for linux, /usr/bin/git, is set in configure system, and for the Linux slave.
The slave is ignoring this in the pre-build SCM step, and using the default windows git from windows.
[EnvInject] - Loading node environment variables. [EnvInject] - Preparing an environment for the build. [EnvInject] - Keeping Jenkins system variables. [EnvInject] - Keeping Jenkins build variables. [EnvInject] - Executing and processing the following script content: printenv
[jenkins-slave-61] $ bash -xe /tmp/hudson1628961445242564055.sh + printenv BUILD_URL=http://192.168.29.61:8080/job/ambiqtools-eclipse-installer/6/ XDG_SESSION_ID=42 HUDSON_SERVER_COOKIE=7b724dbd927d388d SHELL=/bin/bash SSH_CLIENT=192.168.29.61 51590 22 BUILD_TAG=jenkins-ambiqtools-eclipse-installer-6 ROOT_BUILD_CAUSE=MANUALTRIGGER JOB_URL=http://192.168.29.61:8080/job/ambiqtools-eclipse-installer/ USER=rfoos executor label=kvm-u1504-mars JENKINS_HOME=C:\jenkins MAIL=/var/mail/rfoos PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games _=/usr/bin/printenv BUILD_CAUSE_MANUALTRIGGER=true PWD=/home/rfoos/jenkins-slave-61 HUDSON_URL=http://192.168.29.61:8080/ LANG=en_US.UTF-8 JOB_NAME=ambiqtools-eclipse-installer BUILD_DISPLAY_NAME=#6 JENKINS_URL=http://192.168.29.61:8080/ BUILD_CAUSE=MANUALTRIGGER BUILD_ID=6 SHLVL=2 HOME=/home/rfoos EXECUTOR_NUMBER=0 JENKINS_SERVER_COOKIE=7b724dbd927d388d NODE_LABELS=jenkins-slave-61 kvm-u1504-mars LOGNAME=rfoos SSH_CONNECTION=192.168.29.61 51590 192.168.29.153 22 HUDSON_HOME=C:\jenkins NODE_NAME=kvm-u1504-mars BUILD_NUMBER=6 XDG_RUNTIME_DIR=/run/user/1000 ROOT_BUILD_CAUSE_MANUALTRIGGER=true HUDSON_COOKIE=f54968a0-ef1a-4adc-9ef9-f21caec71a68 [EnvInject] - Script executed successfully. [EnvInject] - Injecting contributions. Building remotely on kvm-u1504-mars (jenkins-slave-61) in workspace /home/rfoos/jenkins-slave-61/sharedspace/ambiqtools-eclipse-installer Cloning the remote Git repository Cloning repository http://git.eclipse.org/gitroot/oomph/org.eclipse.oomph.git > C:\Cygwin64\bin\git.exe init /home/rfoos/jenkins-slave-61/sharedspace/ambiqtools-eclipse-installer # timeout=10 ERROR: Error cloning remote repo 'origin' hudson.plugins.git.GitException: Could not init /home/rfoos/jenkins-slave-61/sharedspace/ambiqtools-eclipse-installer at org.jenkinsci.plugins.gitclient.CliGitAPIImpl$4.execute(CliGitAPIImpl.java:606) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl$2.execute(CliGitAPIImpl.java:462) at org.jenkinsci.plugins.gitclient.RemoteGitImpl$CommandInvocationHandler$1.call(RemoteGitImpl.java:152) at org.jenkinsci.plugins.gitclient.RemoteGitImpl$CommandInvocationHandler$1.call(RemoteGitImpl.java:145) at hudson.remoting.UserRequest.perform(UserRequest.java:121) at hudson.remoting.UserRequest.perform(UserRequest.java:49) at hudson.remoting.Request$2.run(Request.java:326) at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:68) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745) at ......remote call to kvm-u1504-mars(Native Method) at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1413) at hudson.remoting.UserResponse.retrieve(UserRequest.java:221) at hudson.remoting.Channel.call(Channel.java:778) at org.jenkinsci.plugins.gitclient.RemoteGitImpl$CommandInvocationHandler.execute(RemoteGitImpl.java:145) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.jenkinsci.plugins.gitclient.RemoteGitImpl$CommandInvocationHandler.invoke(RemoteGitImpl.java:131) at com.sun.proxy.$Proxy68.execute(Unknown Source) at hudson.plugins.git.GitSCM.retrieveChanges(GitSCM.java:1003) at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1043) at org.jenkinsci.plugins.multiplescms.MultiSCM.checkout(MultiSCM.java:129) at hudson.scm.SCM.checkout(SCM.java:485) at hudson.model.AbstractProject.checkout(AbstractProject.java:1277) at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:610) at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:86) at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:532) at hudson.model.Run.execute(Run.java:1741) at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:531) at hudson.model.ResourceController.execute(ResourceController.java:98) at hudson.model.Executor.run(Executor.java:408) Caused by: hudson.plugins.git.GitException: Error performing command: C:\Cygwin64\bin\git.exe init /home/rfoos/jenkins-slave-61/sharedspace/ambiqtools-eclipse-installer at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1647) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1616) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1612) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommand(CliGitAPIImpl.java:1254) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl$4.execute(CliGitAPIImpl.java:604) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl$2.execute(CliGitAPIImpl.java:462) at org.jenkinsci.plugins.gitclient.RemoteGitImpl$CommandInvocationHandler$1.call(RemoteGitImpl.java:152) at org.jenkinsci.plugins.gitclient.RemoteGitImpl$CommandInvocationHandler$1.call(RemoteGitImpl.java:145) at hudson.remoting.UserRequest.perform(UserRequest.java:121) at hudson.remoting.UserRequest.perform(UserRequest.java:49) at hudson.remoting.Request$2.run(Request.java:326) at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:68) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745) Caused by: java.io.IOException: Cannot run program "C:\Cygwin64\bin\git.exe" (in directory "/home/rfoos/jenkins-slave-61/sharedspace/ambiqtools-eclipse-installer"): error=2, No such file or directory at java.lang.ProcessBuilder.start(ProcessBuilder.java:1048) at hudson.Proc$LocalProc.<init>(Proc.java:244) at hudson.Proc$LocalProc.<init>(Proc.java:216) at hudson.Launcher$LocalLauncher.launch(Launcher.java:816) at hudson.Launcher$ProcStarter.start(Launcher.java:382) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1636) ... 15 more Caused by: java.io.IOException: error=2, No such file or directory at java.lang.UNIXProcess.forkAndExec(Native Method) at java.lang.UNIXProcess.<init>(UNIXProcess.java:248) at java.lang.ProcessImpl.start(ProcessImpl.java:134) at java.lang.ProcessBuilder.start(ProcessBuilder.java:1029) ... 20 more ERROR: null Archiving artifacts Finished: FAILURE
|