mhudson.util.IOException2: hudson.plugins.git.GitException: Command "git init" returned status code 128: stdout: stderr: fatal: cannot copy 'C:\Program Files\Git/share/git-core/templates/hooks/post-update.sample' to 'C:/DOCUME~1/!SYSCA~1/LOCALS~1/Temp/.git/hooks/post-update.sample': File exists

Jenkins JIRA | Marcus Bristol | 3 years ago
  1. 0

    After a remote trigger the git init command failed with the following exception: Started on 5/03/2014 1:42:45 PM Using strategy: Default [poll] Last Built Revision: Revision 6c615c2d4570d1aa9288afd73588a7328073e832 (origin/master) using .gitcredentials to set credentials Could not remove the credential section from the git configuration FATAL: hudson.plugins.git.GitException: Command "git init" returned status code 128: stdout: stderr: fatal: cannot copy 'C:\Program Files\Git/share/git-core/templates/description' to 'C:/DOCUME~1/!SYSCA~1/LOCALS~1/Temp/.git/description': File exists ha:AAAAWB+LCAAAAAAAAP9b85aBtbiIQSmjNKU4P08vOT+vOD8nVc8DzHWtSE4tKMnMz/PLL0ldFVf2c+b/lb5MDAwVRQxSaBqcITRIIQMEMIIUFgAAckCEiWAAAAA=hudson.util.IOException2: hudson.plugins.git.GitException: Command "git init" returned status code 128: stdout: stderr: fatal: cannot copy 'C:\Program Files\Git/share/git-core/templates/description' to 'C:/DOCUME~1/!SYSCA~1/LOCALS~1/Temp/.git/description': File exists at hudson.plugins.git.GitSCM.compareRemoteRevisionWith(GitSCM.java:459) at hudson.scm.SCM._compareRemoteRevisionWith(SCM.java:356) at hudson.scm.SCM.poll(SCM.java:373) at hudson.model.AbstractProject._poll(AbstractProject.java:1581) at hudson.model.AbstractProject.poll(AbstractProject.java:1490) at hudson.triggers.SCMTrigger$Runner.runPolling(SCMTrigger.java:462) at hudson.triggers.SCMTrigger$Runner.run(SCMTrigger.java:491) at hudson.util.SequentialExecutionQueue$QueueEntry.run(SequentialExecutionQueue.java:118) at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source) 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 java.lang.Thread.run(Unknown Source) Caused by: hudson.plugins.git.GitException: Command "git init" returned status code 128: stdout: stderr: fatal: cannot copy 'C:\Program Files\Git/share/git-core/templates/description' to 'C:/DOCUME~1/!SYSCA~1/LOCALS~1/Temp/.git/description': File exists at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1173) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1150) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1146) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1142) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandWithCredentials(CliGitAPIImpl.java:1035) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandWithCredentials(CliGitAPIImpl.java:988) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandWithCredentials(CliGitAPIImpl.java:979) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.getHeadRev(CliGitAPIImpl.java:1526) at hudson.plugins.git.GitSCM.compareRemoteRevisionWithImpl(GitSCM.java:489) at hudson.plugins.git.GitSCM.compareRemoteRevisionWith(GitSCM.java:457) ... 13 more Done. Took 0.5 sec No changes The second time it failed with a similar exception: Started on 5/03/2014 1:46:38 PM Using strategy: Default [poll] Last Built Revision: Revision 6c615c2d4570d1aa9288afd73588a7328073e832 (origin/master) using .gitcredentials to set credentials Could not remove the credential section from the git configuration FATAL: hudson.plugins.git.GitException: Command "git init" returned status code 128: stdout: stderr: fatal: cannot copy 'C:\Program Files\Git/share/git-core/templates/hooks/post-update.sample' to 'C:/DOCUME~1/!SYSCA~1/LOCALS~1/Temp/.git/hooks/post-update.sample': File exists ha:AAAAWB+LCAAAAAAAAP9b85aBtbiIQSmjNKU4P08vOT+vOD8nVc8DzHWtSE4tKMnMz/PLL0ldFVf2c+b/lb5MDAwVRQxSaBqcITRIIQMEMIIUFgAAckCEiWAAAAA=hudson.util.IOException2: hudson.plugins.git.GitException: Command "git init" returned status code 128: stdout: stderr: fatal: cannot copy 'C:\Program Files\Git/share/git-core/templates/hooks/post-update.sample' to 'C:/DOCUME~1/!SYSCA~1/LOCALS~1/Temp/.git/hooks/post-update.sample': File exists at hudson.plugins.git.GitSCM.compareRemoteRevisionWith(GitSCM.java:459) at hudson.scm.SCM._compareRemoteRevisionWith(SCM.java:356) at hudson.scm.SCM.poll(SCM.java:373) at hudson.model.AbstractProject._poll(AbstractProject.java:1581) at hudson.model.AbstractProject.poll(AbstractProject.java:1490) at hudson.triggers.SCMTrigger$Runner.runPolling(SCMTrigger.java:462) at hudson.triggers.SCMTrigger$Runner.run(SCMTrigger.java:491) at hudson.util.SequentialExecutionQueue$QueueEntry.run(SequentialExecutionQueue.java:118) at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source) 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 java.lang.Thread.run(Unknown Source) Caused by: hudson.plugins.git.GitException: Command "git init" returned status code 128: stdout: stderr: fatal: cannot copy 'C:\Program Files\Git/share/git-core/templates/hooks/post-update.sample' to 'C:/DOCUME~1/!SYSCA~1/LOCALS~1/Temp/.git/hooks/post-update.sample': File exists at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1173) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1150) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1146) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1142) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandWithCredentials(CliGitAPIImpl.java:1035) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandWithCredentials(CliGitAPIImpl.java:988) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandWithCredentials(CliGitAPIImpl.java:979) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.getHeadRev(CliGitAPIImpl.java:1526) at hudson.plugins.git.GitSCM.compareRemoteRevisionWithImpl(GitSCM.java:489) at hudson.plugins.git.GitSCM.compareRemoteRevisionWith(GitSCM.java:457) ... 13 more Done. Took 0.31 sec No changes Both times the .git folder had been deleted before triggering.

    Jenkins JIRA | 3 years ago | Marcus Bristol
    mhudson.util.IOException2: hudson.plugins.git.GitException: Command "git init" returned status code 128: stdout: stderr: fatal: cannot copy 'C:\Program Files\Git/share/git-core/templates/hooks/post-update.sample' to 'C:/DOCUME~1/!SYSCA~1/LOCALS~1/Temp/.git/hooks/post-update.sample': File exists
  2. 0

    After a remote trigger the git init command failed with the following exception: Started on 5/03/2014 1:42:45 PM Using strategy: Default [poll] Last Built Revision: Revision 6c615c2d4570d1aa9288afd73588a7328073e832 (origin/master) using .gitcredentials to set credentials Could not remove the credential section from the git configuration FATAL: hudson.plugins.git.GitException: Command "git init" returned status code 128: stdout: stderr: fatal: cannot copy 'C:\Program Files\Git/share/git-core/templates/description' to 'C:/DOCUME~1/!SYSCA~1/LOCALS~1/Temp/.git/description': File exists ha:AAAAWB+LCAAAAAAAAP9b85aBtbiIQSmjNKU4P08vOT+vOD8nVc8DzHWtSE4tKMnMz/PLL0ldFVf2c+b/lb5MDAwVRQxSaBqcITRIIQMEMIIUFgAAckCEiWAAAAA=hudson.util.IOException2: hudson.plugins.git.GitException: Command "git init" returned status code 128: stdout: stderr: fatal: cannot copy 'C:\Program Files\Git/share/git-core/templates/description' to 'C:/DOCUME~1/!SYSCA~1/LOCALS~1/Temp/.git/description': File exists at hudson.plugins.git.GitSCM.compareRemoteRevisionWith(GitSCM.java:459) at hudson.scm.SCM._compareRemoteRevisionWith(SCM.java:356) at hudson.scm.SCM.poll(SCM.java:373) at hudson.model.AbstractProject._poll(AbstractProject.java:1581) at hudson.model.AbstractProject.poll(AbstractProject.java:1490) at hudson.triggers.SCMTrigger$Runner.runPolling(SCMTrigger.java:462) at hudson.triggers.SCMTrigger$Runner.run(SCMTrigger.java:491) at hudson.util.SequentialExecutionQueue$QueueEntry.run(SequentialExecutionQueue.java:118) at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source) 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 java.lang.Thread.run(Unknown Source) Caused by: hudson.plugins.git.GitException: Command "git init" returned status code 128: stdout: stderr: fatal: cannot copy 'C:\Program Files\Git/share/git-core/templates/description' to 'C:/DOCUME~1/!SYSCA~1/LOCALS~1/Temp/.git/description': File exists at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1173) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1150) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1146) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1142) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandWithCredentials(CliGitAPIImpl.java:1035) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandWithCredentials(CliGitAPIImpl.java:988) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandWithCredentials(CliGitAPIImpl.java:979) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.getHeadRev(CliGitAPIImpl.java:1526) at hudson.plugins.git.GitSCM.compareRemoteRevisionWithImpl(GitSCM.java:489) at hudson.plugins.git.GitSCM.compareRemoteRevisionWith(GitSCM.java:457) ... 13 more Done. Took 0.5 sec No changes The second time it failed with a similar exception: Started on 5/03/2014 1:46:38 PM Using strategy: Default [poll] Last Built Revision: Revision 6c615c2d4570d1aa9288afd73588a7328073e832 (origin/master) using .gitcredentials to set credentials Could not remove the credential section from the git configuration FATAL: hudson.plugins.git.GitException: Command "git init" returned status code 128: stdout: stderr: fatal: cannot copy 'C:\Program Files\Git/share/git-core/templates/hooks/post-update.sample' to 'C:/DOCUME~1/!SYSCA~1/LOCALS~1/Temp/.git/hooks/post-update.sample': File exists ha:AAAAWB+LCAAAAAAAAP9b85aBtbiIQSmjNKU4P08vOT+vOD8nVc8DzHWtSE4tKMnMz/PLL0ldFVf2c+b/lb5MDAwVRQxSaBqcITRIIQMEMIIUFgAAckCEiWAAAAA=hudson.util.IOException2: hudson.plugins.git.GitException: Command "git init" returned status code 128: stdout: stderr: fatal: cannot copy 'C:\Program Files\Git/share/git-core/templates/hooks/post-update.sample' to 'C:/DOCUME~1/!SYSCA~1/LOCALS~1/Temp/.git/hooks/post-update.sample': File exists at hudson.plugins.git.GitSCM.compareRemoteRevisionWith(GitSCM.java:459) at hudson.scm.SCM._compareRemoteRevisionWith(SCM.java:356) at hudson.scm.SCM.poll(SCM.java:373) at hudson.model.AbstractProject._poll(AbstractProject.java:1581) at hudson.model.AbstractProject.poll(AbstractProject.java:1490) at hudson.triggers.SCMTrigger$Runner.runPolling(SCMTrigger.java:462) at hudson.triggers.SCMTrigger$Runner.run(SCMTrigger.java:491) at hudson.util.SequentialExecutionQueue$QueueEntry.run(SequentialExecutionQueue.java:118) at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source) 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 java.lang.Thread.run(Unknown Source) Caused by: hudson.plugins.git.GitException: Command "git init" returned status code 128: stdout: stderr: fatal: cannot copy 'C:\Program Files\Git/share/git-core/templates/hooks/post-update.sample' to 'C:/DOCUME~1/!SYSCA~1/LOCALS~1/Temp/.git/hooks/post-update.sample': File exists at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1173) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1150) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1146) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1142) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandWithCredentials(CliGitAPIImpl.java:1035) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandWithCredentials(CliGitAPIImpl.java:988) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandWithCredentials(CliGitAPIImpl.java:979) at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.getHeadRev(CliGitAPIImpl.java:1526) at hudson.plugins.git.GitSCM.compareRemoteRevisionWithImpl(GitSCM.java:489) at hudson.plugins.git.GitSCM.compareRemoteRevisionWith(GitSCM.java:457) ... 13 more Done. Took 0.31 sec No changes Both times the .git folder had been deleted before triggering.

    Jenkins JIRA | 3 years ago | Marcus Bristol
    mhudson.util.IOException2: hudson.plugins.git.GitException: Command "git init" returned status code 128: stdout: stderr: fatal: cannot copy 'C:\Program Files\Git/share/git-core/templates/hooks/post-update.sample' to 'C:/DOCUME~1/!SYSCA~1/LOCALS~1/Temp/.git/hooks/post-update.sample': File exists
  3. 0

    Jenkins node fails to poll changes

    GitHub | 2 years ago | vircung
    hudson.util.IOException2: hudson.plugins.git.GitException: Command "/usr/bin/git ls-remote -h ssh://git@gitlab.---------------------------------------.git develop" returned status code 128: stdout: stderr: Access denied. fatal: The remote end hung up unexpectedly
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    Authentication problem (?) when building through a Github webhook

    Google Groups | 3 years ago | Scott Purcell
    hudson.util.IOException2: hudson.plugins.git.GitException: Failed to connect to https://<obfuscated-Oauth-token>@github.com/cloud-training/Course-OSFundamentals-Dev.git (status = 401)
  6. 0

    [JENKINS-21914] Intermittent Git(hub) polling errors on Windows - Jenkins JIRA

    jenkins-ci.org | 1 year ago
    hudson.util.IOException2: hudson.plugins.git.GitException: Command "git config --local credential.helper store --file=\"C:\Windows\TEMP\git4966117369976036349.credentials\"" returned status code 255: stdout: stderr: error: could not lock config file .git/config: File exists

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. hudson.plugins.git.GitException

      Command "git init" returned status code 128: stdout: stderr: fatal: cannot copy 'C:\Program Files\Git/share/git-core/templates/hooks/post-update.sample' to 'C:/DOCUME~1/!SYSCA~1/LOCALS~1/Temp/.git/hooks/post-update.sample': File exists

      at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn()
    2. org.jenkinsci.plugins
      CliGitAPIImpl.getHeadRev
      1. org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1173)
      2. org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1150)
      3. org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1146)
      4. org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1142)
      5. org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandWithCredentials(CliGitAPIImpl.java:1035)
      6. org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandWithCredentials(CliGitAPIImpl.java:988)
      7. org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandWithCredentials(CliGitAPIImpl.java:979)
      8. org.jenkinsci.plugins.gitclient.CliGitAPIImpl.getHeadRev(CliGitAPIImpl.java:1526)
      8 frames
    3. Hudson GIT plugin
      GitSCM.compareRemoteRevisionWith
      1. hudson.plugins.git.GitSCM.compareRemoteRevisionWithImpl(GitSCM.java:489)
      2. hudson.plugins.git.GitSCM.compareRemoteRevisionWith(GitSCM.java:457)
      2 frames
    4. Hudson
      SequentialExecutionQueue$QueueEntry.run
      1. hudson.scm.SCM._compareRemoteRevisionWith(SCM.java:356)
      2. hudson.scm.SCM.poll(SCM.java:373)
      3. hudson.model.AbstractProject._poll(AbstractProject.java:1581)
      4. hudson.model.AbstractProject.poll(AbstractProject.java:1490)
      5. hudson.triggers.SCMTrigger$Runner.runPolling(SCMTrigger.java:462)
      6. hudson.triggers.SCMTrigger$Runner.run(SCMTrigger.java:491)
      7. hudson.util.SequentialExecutionQueue$QueueEntry.run(SequentialExecutionQueue.java:118)
      7 frames
    5. Java RT
      Thread.run
      1. java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
      2. java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source)
      3. java.util.concurrent.FutureTask.run(Unknown Source)
      4. java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
      5. java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
      6. java.lang.Thread.run(Unknown Source)
      6 frames