java.lang.RuntimeException: git plugin only support official git client http://git-scm.com/download/win

Jenkins JIRA | Mark Waite | 3 years ago
tip
Click on the to mark the solution that helps you, Samebug will learn from it.
As a community member, you’ll be rewarded for you help.
  1. 0

    The GIT_SSH fix for JENKINS-20356 only works if the Git program is installed in the default location on Windows. I had installed to a different location and had updated the PATH variable to find that non-default location. All the typical plugin operations worked, except this recently added code for JENKINS-20356 was not able to find ssh.exe. The message is misleading, since the issue is not that the plugin only supports official git client. The plugin could not find the ssh.exe program on the simple paths it checked. Unfortunately, it did not search the PATH, it only searched in the ProgramFiles directory, and I had installed to a different drive in order to save space on a small disc that was hosting ProgramFiles. Stack trace looks like this: {noformat} Started by user anonymous Building remotely on alan-pc in workspace C:\J\workspace\JENKINS-20356 Cloning the remote Git repository Cloning repository ssh://wheezy64b/var/cache/git/mwaite/bin.git Fetching upstream changes from ssh://wheezy64b/var/cache/git/mwaite/bin.git using GIT_SSH to set credentials Jenkins FATAL: git plugin only support official git client http://git-scm.com/download/win java.lang.RuntimeException: git plugin only support official git client http://git-scm.com/download/win at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.createWindowsGitSSH(CliGitAPIImpl.java:1053) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandWithCredentials(CliGitAPIImpl.java:963) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.access$200(CliGitAPIImpl.java:68) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl$1.execute(CliGitAPIImpl.java:217) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl$2.execute(CliGitAPIImpl.java:349) 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:118) at hudson.remoting.UserRequest.perform(UserRequest.java:48) at hudson.remoting.Request$2.run(Request.java:326) at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72) at java.util.concurrent.FutureTask.run(Unknown Source) at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) at hudson.remoting.Engine$1$1.run(Engine.java:63) at java.lang.Thread.run(Unknown Source) {noformat}

    Jenkins JIRA | 3 years ago | Mark Waite
    java.lang.RuntimeException: git plugin only support official git client http://git-scm.com/download/win
  2. 0

    The GIT_SSH fix for JENKINS-20356 only works if the Git program is installed in the default location on Windows. I had installed to a different location and had updated the PATH variable to find that non-default location. All the typical plugin operations worked, except this recently added code for JENKINS-20356 was not able to find ssh.exe. The message is misleading, since the issue is not that the plugin only supports official git client. The plugin could not find the ssh.exe program on the simple paths it checked. Unfortunately, it did not search the PATH, it only searched in the ProgramFiles directory, and I had installed to a different drive in order to save space on a small disc that was hosting ProgramFiles. Stack trace looks like this: {noformat} Started by user anonymous Building remotely on alan-pc in workspace C:\J\workspace\JENKINS-20356 Cloning the remote Git repository Cloning repository ssh://wheezy64b/var/cache/git/mwaite/bin.git Fetching upstream changes from ssh://wheezy64b/var/cache/git/mwaite/bin.git using GIT_SSH to set credentials Jenkins FATAL: git plugin only support official git client http://git-scm.com/download/win java.lang.RuntimeException: git plugin only support official git client http://git-scm.com/download/win at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.createWindowsGitSSH(CliGitAPIImpl.java:1053) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandWithCredentials(CliGitAPIImpl.java:963) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.access$200(CliGitAPIImpl.java:68) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl$1.execute(CliGitAPIImpl.java:217) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl$2.execute(CliGitAPIImpl.java:349) 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:118) at hudson.remoting.UserRequest.perform(UserRequest.java:48) at hudson.remoting.Request$2.run(Request.java:326) at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72) at java.util.concurrent.FutureTask.run(Unknown Source) at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) at hudson.remoting.Engine$1$1.run(Engine.java:63) at java.lang.Thread.run(Unknown Source) {noformat}

    Jenkins JIRA | 3 years ago | Mark Waite
    java.lang.RuntimeException: git plugin only support official git client http://git-scm.com/download/win

    Root Cause Analysis

    1. java.lang.RuntimeException

      git plugin only support official git client http://git-scm.com/download/win

      at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.createWindowsGitSSH()
    2. org.jenkinsci.plugins
      RemoteGitImpl$CommandInvocationHandler$1.call
      1. org.jenkinsci.plugins.gitclient.CliGitAPIImpl.createWindowsGitSSH(CliGitAPIImpl.java:1053)
      2. org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandWithCredentials(CliGitAPIImpl.java:963)
      3. org.jenkinsci.plugins.gitclient.CliGitAPIImpl.access$200(CliGitAPIImpl.java:68)
      4. org.jenkinsci.plugins.gitclient.CliGitAPIImpl$1.execute(CliGitAPIImpl.java:217)
      5. org.jenkinsci.plugins.gitclient.CliGitAPIImpl$2.execute(CliGitAPIImpl.java:349)
      6. org.jenkinsci.plugins.gitclient.RemoteGitImpl$CommandInvocationHandler$1.call(RemoteGitImpl.java:152)
      7. org.jenkinsci.plugins.gitclient.RemoteGitImpl$CommandInvocationHandler$1.call(RemoteGitImpl.java:145)
      7 frames
    3. Hudson :: Remoting Layer
      InterceptingExecutorService$1.call
      1. hudson.remoting.UserRequest.perform(UserRequest.java:118)
      2. hudson.remoting.UserRequest.perform(UserRequest.java:48)
      3. hudson.remoting.Request$2.run(Request.java:326)
      4. hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72)
      4 frames
    4. Java RT
      ThreadPoolExecutor$Worker.run
      1. java.util.concurrent.FutureTask.run(Unknown Source)
      2. java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
      3. java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
      3 frames
    5. Hudson :: Remoting Layer
      Engine$1$1.run
      1. hudson.remoting.Engine$1$1.run(Engine.java:63)
      1 frame
    6. Java RT
      Thread.run
      1. java.lang.Thread.run(Unknown Source)
      1 frame