1

Installed the git-lfs on our mac slaves and followed the artical at https://medium.com/@priya_talreja/git-lfs-setup-in-jenkins-ee80879007e3. to build jenkins job

we are getting the following error:

Git LFS initialized.     
xxxx
xxxx
xxxx
Enabling Git LFS pull
 > git config core.sparsecheckout # timeout=10
 > git checkout -f 94723c3732a48a49f41a70248233e52b015632cb # timeout=10
 > git config --get remote.origin.url # timeout=10
 > git lfs pull origin # timeout=10
FATAL: Could not checkout 94723c3732a48a49f41a70248233e52b015632cb
hudson.plugins.git.GitException: Command "git lfs pull origin" returned status code 1:
stdout: 
stderr: git: 'lfs' is not a git command. See 'git --help'. 

out of 4 nodes, one node is working others are not. [Mac OS X; Version: 10.14.6] git versions : 2.22.0 / 2.21.0 /2.23.0 [Error getting on ver: 2.22.0 and 2.23.0] git-lfs version: 2.11.0

sai kumar
  • 113
  • 2
  • 9
  • 1
    One of the mac slave does not have git lfs installed: https://stackoverflow.com/a/58796646/6309 – VonC Jun 25 '20 at 05:54
  • git lfs was installed on mac slave. after adding the git installation path in node configuration, error disappeared. – sai kumar Jul 01 '20 at 03:11
  • In my case, git lfs was not installed on my redhat 7 machine... followed below steps in link to make it work. https://github.com/git-lfs/git-lfs/wiki/Installation – Tapan Hegde Sep 01 '21 at 13:57

1 Answers1

0

Faced same issue in my RHEL-7 machine and followed below steps to make it work. (git lfs was missing in my machine, installed same using below steps)

 $ sudo yum install git

 $ curl -s https://setup.ius.io/ | sudo bash 

 $ sudo yum install git2u

 $ curl -s https://packagecloud.io/install/repositories/github/git-lfs/script.rpm.sh | sudo bash

 $ sudo yum install git-lfs

 $ git lfs install

Reference link : https://github.com/git-lfs/git-lfs/wiki/Installation

Tapan Hegde
  • 1,222
  • 1
  • 8
  • 25