hudson.plugins.git.GitException: Could not clone https://github.com/EMSL-MSC/go-rpms.git

There are no available Samebug tips for this exception. Do you have an idea how to solve this issue? A short tip would help users who saw this issue last week.

  • For some reason I can't clone or update git jobs after updating to Jenkins 1.536. I can see that it calls git --version but it never seems to call git clone. I've verified this by wrapping the git command with a shell script to log it. I've blown away the workspace and had Jenkins rebuild it, still produces the same git error. Last Built Revision: Revision 1480f9f672147b2e1b7daad55dc74048fa977bf1 (origin/master) Cloning the remote Git repository Cloning repository https://github.com/EMSL-MSC/go-rpms.git git --version git version 1.7.1 ERROR: Error cloning remote repo 'origin' : Could not clone https://github.com/EMSL-MSC/go-rpms.git hudson.plugins.git.GitException: Could not clone https://github.com/EMSL-MSC/go-rpms.git at org.jenkinsci.plugins.gitclient.CliGitAPIImpl$1.execute(CliGitAPIImpl.java:286) at org.jenkinsci.plugins.gitclient.AbstractGitAPIImpl.clone(AbstractGitAPIImpl.java:59) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.clone(CliGitAPIImpl.java:47) at hudson.plugins.git.GitSCM$2.invoke(GitSCM.java:1012) at hudson.plugins.git.GitSCM$2.invoke(GitSCM.java:948) at hudson.FilePath.act(FilePath.java:912) at hudson.FilePath.act(FilePath.java:885) at hudson.plugins.git.GitSCM.determineRevisionToBuild(GitSCM.java:948) at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1114) at hudson.model.AbstractProject.checkout(AbstractProject.java:1411) at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:652) at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:88) at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:557) at hudson.model.Run.execute(Run.java:1665) at hudson.matrix.MatrixBuild.run(MatrixBuild.java:304) at hudson.model.ResourceController.execute(ResourceController.java:88) at hudson.model.Executor.run(Executor.java:230) at hudson.model.OneOffExecutor.run(OneOffExecutor.java:43) Caused by: hudson.plugins.git.GitException: Failed to connect to https://github.com/EMSL-MSC/go-rpms.git at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.getURLWithCrendentials(CliGitAPIImpl.java:1374) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.getURLWithCrendentials(CliGitAPIImpl.java:1326) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.access$300(CliGitAPIImpl.java:47) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl$1.execute(CliGitAPIImpl.java:280) ... 17 more Trying next repository ERROR: Could not clone repository java.io.IOException: Could not clone at hudson.plugins.git.GitSCM$2.invoke(GitSCM.java:1025) at hudson.plugins.git.GitSCM$2.invoke(GitSCM.java:948) at hudson.FilePath.act(FilePath.java:912) at hudson.FilePath.act(FilePath.java:885) at hudson.plugins.git.GitSCM.determineRevisionToBuild(GitSCM.java:948) at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1114) at hudson.model.AbstractProject.checkout(AbstractProject.java:1411) at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:652) at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:88) at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:557) at hudson.model.Run.execute(Run.java:1665) at hudson.matrix.MatrixBuild.run(MatrixBuild.java:304) at hudson.model.ResourceController.execute(ResourceController.java:88) at hudson.model.Executor.run(Executor.java:230) at hudson.model.OneOffExecutor.run(OneOffExecutor.java:43) Finished: FAILURE
    via by David Brown,
  • For some reason I can't clone or update git jobs after updating to Jenkins 1.536. I can see that it calls git --version but it never seems to call git clone. I've verified this by wrapping the git command with a shell script to log it. I've blown away the workspace and had Jenkins rebuild it, still produces the same git error. Last Built Revision: Revision 1480f9f672147b2e1b7daad55dc74048fa977bf1 (origin/master) Cloning the remote Git repository Cloning repository https://github.com/EMSL-MSC/go-rpms.git git --version git version 1.7.1 ERROR: Error cloning remote repo 'origin' : Could not clone https://github.com/EMSL-MSC/go-rpms.git hudson.plugins.git.GitException: Could not clone https://github.com/EMSL-MSC/go-rpms.git at org.jenkinsci.plugins.gitclient.CliGitAPIImpl$1.execute(CliGitAPIImpl.java:286) at org.jenkinsci.plugins.gitclient.AbstractGitAPIImpl.clone(AbstractGitAPIImpl.java:59) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.clone(CliGitAPIImpl.java:47) at hudson.plugins.git.GitSCM$2.invoke(GitSCM.java:1012) at hudson.plugins.git.GitSCM$2.invoke(GitSCM.java:948) at hudson.FilePath.act(FilePath.java:912) at hudson.FilePath.act(FilePath.java:885) at hudson.plugins.git.GitSCM.determineRevisionToBuild(GitSCM.java:948) at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1114) at hudson.model.AbstractProject.checkout(AbstractProject.java:1411) at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:652) at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:88) at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:557) at hudson.model.Run.execute(Run.java:1665) at hudson.matrix.MatrixBuild.run(MatrixBuild.java:304) at hudson.model.ResourceController.execute(ResourceController.java:88) at hudson.model.Executor.run(Executor.java:230) at hudson.model.OneOffExecutor.run(OneOffExecutor.java:43) Caused by: hudson.plugins.git.GitException: Failed to connect to https://github.com/EMSL-MSC/go-rpms.git at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.getURLWithCrendentials(CliGitAPIImpl.java:1374) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.getURLWithCrendentials(CliGitAPIImpl.java:1326) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.access$300(CliGitAPIImpl.java:47) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl$1.execute(CliGitAPIImpl.java:280) ... 17 more Trying next repository ERROR: Could not clone repository java.io.IOException: Could not clone at hudson.plugins.git.GitSCM$2.invoke(GitSCM.java:1025) at hudson.plugins.git.GitSCM$2.invoke(GitSCM.java:948) at hudson.FilePath.act(FilePath.java:912) at hudson.FilePath.act(FilePath.java:885) at hudson.plugins.git.GitSCM.determineRevisionToBuild(GitSCM.java:948) at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1114) at hudson.model.AbstractProject.checkout(AbstractProject.java:1411) at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:652) at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:88) at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:557) at hudson.model.Run.execute(Run.java:1665) at hudson.matrix.MatrixBuild.run(MatrixBuild.java:304) at hudson.model.ResourceController.execute(ResourceController.java:88) at hudson.model.Executor.run(Executor.java:230) at hudson.model.OneOffExecutor.run(OneOffExecutor.java:43) Finished: FAILURE
    via by David Brown,
  • Jenkins Git plugin with https
    via Stack Overflow by Christina
    ,
  • Unable to integrate jenkins and git
    via Stack Overflow by geek gugi
    ,
  • The git plugin "Advanced" configuration section accepts a "reference" repository path. Previously, if there was a value in that path and if that path existed, then the --reference argument was added to the "git clone" and the clone was able to dramatically reduce the time to clone and the disc space used by that cloned copy of the repository, especially for large repositories. With the plugin version 1.2.0, if a reference value is given, it must exist, otherwise the clone operation fails with a message in the stack trace that the reference repository does not exist. That is very inconvenient for my use case, since some of my slave agents have the reference repository in that location, and others do not. Previously, that meant some of the slaves needed more disc space than others to clone this large repository, but they were still able to clone the repository. With the new implementation, if the reference directory does not exist on all slaves, I must either remove the reference argument or must assure that all slaves have that reference directory available. Stack trace is: ERROR: Error cloning remote repo 'origin' : Could not clone git://mwaite6.ptcnet.ptc.com/git/mwaite/bin.git hudson.plugins.git.GitException: Could not clone git://mwaite6.ptcnet.ptc.com/git/mwaite/bin.git at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.clone(CliGitAPIImpl.java:218) at hudson.plugins.git.GitSCM$2.invoke(GitSCM.java:1002) at hudson.plugins.git.GitSCM$2.invoke(GitSCM.java:941) at hudson.FilePath.act(FilePath.java:852) at hudson.FilePath.act(FilePath.java:834) at hudson.plugins.git.GitSCM.determineRevisionToBuild(GitSCM.java:941) at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1113) at hudson.model.AbstractProject.checkout(AbstractProject.java:1256) at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:590) at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:88) at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:495) at hudson.model.Run.execute(Run.java:1502) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46) at hudson.model.ResourceController.execute(ResourceController.java:88) at hudson.model.Executor.run(Executor.java:237) Caused by: hudson.plugins.git.GitException: Reference path does not exist: /var/cache/git/repo-does-not-exist.git at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.clone(CliGitAPIImpl.java:206) ... 14 more Trying next repository ERROR: Could not clone repository FATAL: Could not clone hudson.plugins.git.GitException: Could not clone at hudson.plugins.git.GitSCM$2.invoke(GitSCM.java:1014) at hudson.plugins.git.GitSCM$2.invoke(GitSCM.java:941) at hudson.FilePath.act(FilePath.java:852) at hudson.FilePath.act(FilePath.java:834) at hudson.plugins.git.GitSCM.determineRevisionToBuild(GitSCM.java:941) at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1113) at hudson.model.AbstractProject.checkout(AbstractProject.java:1256) at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:590) at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:88) at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:495) at hudson.model.Run.execute(Run.java:1502) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46) at hudson.model.ResourceController.execute(ResourceController.java:88) at hudson.model.Executor.run(Executor.java:237)
    via by Mark Waite,
  • Hi, I've just reinstalled jenkins on my new server and ported all the old tasks to the new instance. It all works fine, but if I enable the "Wipe out workspace before build" in git plugin(it was previously enabled and working fine), the clone fails leaving the job's workspace with 0666 permissions (so it "chmods a-x" the workspace directory); I checked the umask and it looks correct, it's 0002. If I remove the flag, clearly the workspace doesn't get wiped out but everything works again pretty well. This is the output from the console(I replaced some names): Building in workspace /var/lib/jenkins/jobs/MyProject/workspace Checkout:workspace / /var/lib/jenkins/jobs/MyProject/workspace - hudson.remoting.LocalChannel@20a26542 Using strategy: Default Last Built Revision: Revision ad1e4166745f9e33c9851bdefb7494de9651df23 (origin/master) Using shallow clone Wiping out workspace first. Cloning the remote Git repository Cloning repository git@git.mycompany.com:myproject/myproject-001/myrepository.git Error trying to determine the git version: Error performing command: git --version Assuming 1.6 ERROR: Error cloning remote repo 'origin' : Could not clone git@git.mycompany.com:myproject/myproject-001/myrepository.git hudson.plugins.git.GitException: Could not clone git@git.mycompany.com:myproject/myproject-001/myrepository.git at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.clone(CliGitAPIImpl.java:219) at hudson.plugins.git.GitSCM$2.invoke(GitSCM.java:1002) at hudson.plugins.git.GitSCM$2.invoke(GitSCM.java:941) at hudson.FilePath.act(FilePath.java:865) at hudson.FilePath.act(FilePath.java:838) at hudson.plugins.git.GitSCM.determineRevisionToBuild(GitSCM.java:941) at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1113) at hudson.model.AbstractProject.checkout(AbstractProject.java:1353) at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:689) at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:88) at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:594) at hudson.model.Run.execute(Run.java:1567) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46) at hudson.model.ResourceController.execute(ResourceController.java:88) at hudson.model.Executor.run(Executor.java:237) Caused by: hudson.plugins.git.GitException: Command "git clone -o origin --depth 1 git@git.mycompany.com:myproject/myproject-001/myrepository.git /var/lib/jenkins/jobs/MyProject/workspace" returned status code 128: stdout: stderr: fatal: destination path '/var/lib/jenkins/jobs/MyProject/workspace' already exists and is not an empty directory. at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:773) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.clone(CliGitAPIImpl.java:217) ... 14 more Trying next repository ERROR: Could not clone repository FATAL: Could not clone hudson.plugins.git.GitException: Could not clone at hudson.plugins.git.GitSCM$2.invoke(GitSCM.java:1014) at hudson.plugins.git.GitSCM$2.invoke(GitSCM.java:941) at hudson.FilePath.act(FilePath.java:865) at hudson.FilePath.act(FilePath.java:838) at hudson.plugins.git.GitSCM.determineRevisionToBuild(GitSCM.java:941) at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1113) at hudson.model.AbstractProject.checkout(AbstractProject.java:1353) at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:689) at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:88) at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:594) at hudson.model.Run.execute(Run.java:1567) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46) at hudson.model.ResourceController.execute(ResourceController.java:88) at hudson.model.Executor.run(Executor.java:237) And here's some info on software versions: OS: Ubuntu 12.10 Jenkins: 1.506 Git plugin: 1.30 Git: 1.7.10.4 Java: java version "1.7.0_15" OpenJDK Runtime Environment (IcedTea7 2.3.7) (7u15-2.3.7-0ubuntu1~12.10.1) OpenJDK 64-Bit Server VM (build 23.7-b01, mixed mode)
    via by omissis,
    • hudson.plugins.git.GitException: Could not clone https://github.com/EMSL-MSC/go-rpms.git at org.jenkinsci.plugins.gitclient.CliGitAPIImpl$1.execute(CliGitAPIImpl.java:286) at org.jenkinsci.plugins.gitclient.AbstractGitAPIImpl.clone(AbstractGitAPIImpl.java:59) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.clone(CliGitAPIImpl.java:47) at hudson.plugins.git.GitSCM$2.invoke(GitSCM.java:1012) at hudson.plugins.git.GitSCM$2.invoke(GitSCM.java:948) at hudson.FilePath.act(FilePath.java:912) at hudson.FilePath.act(FilePath.java:885) at hudson.plugins.git.GitSCM.determineRevisionToBuild(GitSCM.java:948) at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1114) at hudson.model.AbstractProject.checkout(AbstractProject.java:1411) at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:652) at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:88) at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:557) at hudson.model.Run.execute(Run.java:1665) at hudson.matrix.MatrixBuild.run(MatrixBuild.java:304) at hudson.model.ResourceController.execute(ResourceController.java:88) at hudson.model.Executor.run(Executor.java:230) at hudson.model.OneOffExecutor.run(OneOffExecutor.java:43) Caused by: hudson.plugins.git.GitException: Failed to connect to https://github.com/EMSL-MSC/go-rpms.git at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.getURLWithCrendentials(CliGitAPIImpl.java:1374) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.getURLWithCrendentials(CliGitAPIImpl.java:1326) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.access$300(CliGitAPIImpl.java:47) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl$1.execute(CliGitAPIImpl.java:280) ... 17 more
    No Bugmate found.