windows - git gc hænger tilfældigt på frisk klon

Indlæg af Hanne Mølgaard Plasc

Problem



Jeg har forsøgt at finde en løsning på de intermitterende hængsler af git-kommandoer (push, pull, repo sync). Jeg har gjort følgende:



  1. Tændt GIT\_TRACE - dette viser, at hangen altid forekommer under en git gc -auto

  2. globalt deaktiveret gc --auto: men repo sync kalder stadig git gc --auto



Det sker kun på Windows. Det er sket med automatiserede processer og individuelle brugere. Nedenfor er spor output fra et Jenkins job på en Windows 10 node kalder repo synkronisering. Er der nogen der ved, hvordan man løser dette problem? Det ER IKKE REPRODUCTIBELT, DERFOR INTERMITTENT. Jeg reproducerer det ved gentagne gange at køre mine jenkins bygge job indtil hænge opstår.


17:37:56 + git config --global gc.auto 0
17:37:56 + /bin/repo init -u ssh://gerritgit/MyProject1 -b amd-master-v3.0 -m Build/manifests/TestSamples.xml
17:38:03 14:37:06.790475 git.c:344               trace: built-in: git 'version'
17:38:04 14:37:07.158739 git.c:344               trace: built-in: git 'fetch' 'origin' '--tags' '+refs/heads/*:refs/remotes/origin/*' '+refs/heads/master:refs/remotes/origin/master'
17:38:04 14:37:07.259343 run-command.c:627       trace: run\_command: 'ssh' 'gerritgit' 'git-upload-pack '''/MyProject1''''
17:38:05 14:37:08.511328 run-command.c:627       trace: run\_command: 'rev-list' '--objects' '--stdin' '--not' '--all' '--quiet'
17:38:05 14:37:08.644315 run-command.c:627       trace: run\_command: 'rev-list' '--objects' '--stdin' '--not' '--all' '--quiet'
17:38:05 14:37:08.697302 git.c:344               trace: built-in: git 'rev-list' '--objects' '--stdin' '--not' '--all' '--quiet'
17:38:05 14:37:08.795747 run-command.c:1470      run\_processes\_parallel: preparing to run up to 1 tasks
17:38:05 14:37:08.795786 run-command.c:1502      run\_processes\_parallel: done
17:38:05 14:37:08.799766 run-command.c:627       trace: run\_command: 'gc' '--auto'
17:38:05 14:37:08.872278 git.c:344               trace: built-in: git 'gc' '--auto'
17:38:06 14:37:09.009433 git.c:344               trace: built-in: git 'checkout' '-q' 'e9d37b3d550dab0166029a4425cbf1d401f164c7' '--'
17:38:06 
17:38:06 repo has been initialized in /cygdrive/c/jenkins/workspace/GPA-Test-Samples
17:38:06 + /bin/repo forall -c 'git reset --hard'
...
17:38:51 + /bin/repo sync -q
17:38:56 14:37:59.605416 git.c:344               trace: built-in: git 'fetch' '--quiet' 'origin' '--tags' '+refs/heads/master:refs/remotes/origin/master'
17:38:56 14:37:59.665265 run-command.c:627       trace: run\_command: 'ssh' 'gerritgit' 'git-upload-pack '''/MyProject1''''
17:38:57 14:38:00.865907 run-command.c:627       trace: run\_command: 'rev-list' '--objects' '--stdin' '--not' '--all' '--quiet'
17:38:58 14:38:00.983850 run-command.c:627       trace: run\_command: 'rev-list' '--objects' '--stdin' '--not' '--all' '--quiet'
17:38:58 14:38:01.025934 git.c:344               trace: built-in: git 'rev-list' '--objects' '--stdin' '--not' '--all' '--quiet'
17:38:58 14:38:01.118542 run-command.c:1470      run\_processes\_parallel: preparing to run up to 1 tasks
17:38:58 14:38:01.118585 run-command.c:1502      run\_processes\_parallel: done
17:38:58 14:38:01.118696 run-command.c:627       trace: run\_command: 'gc' '--auto' '--quiet'
17:38:58 14:38:01.183074 git.c:344               trace: built-in: git 'gc' '--auto' '--quiet'
17:40:03 14:39:06.373539 git.c:344               trace: built-in: git 'fetch' '--quiet' 'gerritgit' '--tags' '+refs/heads/master:refs/remotes/gerritgit/master'
17:40:31 14:39:34.877765 git.c:344               trace: built-in: git 'fetch' '--quiet' 'gerritgit' '--tags' '+refs/heads/master:refs/remotes/gerritgit/master'
17:40:46 14:39:49.251235 run-command.c:627       trace: run\_command: 'ssh' 'gerritgit' 'git-upload-pack '''/MyProject2''''
17:40:56 14:39:59.812070 run-command.c:627       trace: run\_command: 'ssh' 'gerritgit' 'git-upload-pack '''/MyProject3''''
17:41:03 14:40:06.164013 run-command.c:627       trace: run\_command: 'rev-list' '--objects' '--stdin' '--not' '--all' '--quiet'
17:41:18 14:40:21.413661 run-command.c:627       trace: run\_command: 'rev-list' '--objects' '--stdin' '--not' '--all' '--quiet'
17:41:31 14:40:34.373479 run-command.c:627       trace: run\_command: 'rev-list' '--objects' '--stdin' '--not' '--all' '--quiet'
17:41:42 14:40:45.064575 run-command.c:627       trace: run\_command: 'rev-list' '--objects' '--stdin' '--not' '--all' '--quiet'
17:41:46 14:40:49.901994 git.c:344               trace: built-in: git 'rev-list' '--objects' '--stdin' '--not' '--all' '--quiet'
17:41:56 14:40:59.395930 git.c:344               trace: built-in: git 'rev-list' '--objects' '--stdin' '--not' '--all' '--quiet'
17:42:01 14:41:04.149230 run-command.c:1470      run\_processes\_parallel: preparing to run up to 1 tasks
17:42:01 14:41:04.149254 run-command.c:1502      run\_processes\_parallel: done
17:42:01 14:41:04.151747 run-command.c:627       trace: run\_command: 'gc' '--auto' '--quiet'
17:42:10 14:41:13.655746 run-command.c:1470      run\_processes\_parallel: preparing to run up to 1 tasks
17:42:10 14:41:13.655771 run-command.c:1502      run\_processes\_parallel: done
17:42:10 14:41:13.655825 run-command.c:627       trace: run\_command: 'gc' '--auto' '--quiet'
17:42:15 14:41:18.408644 git.c:344               trace: built-in: git 'gc' '--auto' '--quiet'
17:42:21 14:41:24.382829 git.c:344               trace: built-in: git 'gc' '--auto' '--quiet'
17:42:21 14:39:30.144005 git.c:344               trace: built-in: git 'fetch' '--quiet' 'gerritgit' '--tags' '+refs/heads/master:refs/remotes/gerritgit/master'
17:42:21 14:39:44.411421 run-command.c:627       trace: run\_command: 'ssh' 'gerritgit' 'git-upload-pack '''/MyProject4''''
17:42:21 14:40:05.956618 run-command.c:627       trace: run\_command: 'rev-list' '--objects' '--stdin' '--not' '--all' '--quiet'
17:42:21 14:40:24.859062 run-command.c:627       trace: run\_command: 'rev-list' '--objects' '--stdin' '--not' '--all' '--quiet'
17:42:21 14:40:39.376815 git.c:344               trace: built-in: git 'rev-list' '--objects' '--stdin' '--not' '--all' '--quiet'
17:42:21 14:40:54.654943 run-command.c:1470      run\_processes\_parallel: preparing to run up to 1 tasks
17:42:21 14:40:54.654968 run-command.c:1502      run\_processes\_parallel: done
17:42:21 14:40:54.656707 run-command.c:627       trace: run\_command: 'gc' '--auto' '--quiet'
17:42:21 14:41:08.904766 git.c:344               trace: built-in: git 'gc' '--auto' '--quiet'
17:43:30 14:42:33.096806 git.c:344               trace: built-in: git 'fetch' '--quiet' 'gerritgit' '--tags' '+refs/heads/master:refs/remotes/gerritgit/master'
17:43:40 14:42:43.700211 run-command.c:627       trace: run\_command: 'ssh' 'gerritgit' 'git-upload-pack '''/MyProject5''''
17:43:45 14:42:48.442727 git.c:344               trace: built-in: git 'fetch' '--quiet' 'gerritgit' '--tags' '+refs/heads/master:refs/remotes/gerritgit/master'
17:43:55 14:42:57.964075 run-command.c:627       trace: run\_command: 'ssh' 'gerritgit' 'git-upload-pack '''/MyProject6''''
17:44:01 14:43:04.180153 run-command.c:627       trace: run\_command: 'rev-list' '--objects' '--stdin' '--not' '--all' '--quiet'
17:44:14 14:43:16.959125 run-command.c:627       trace: run\_command: 'rev-list' '--objects' '--stdin' '--not' '--all' '--quiet'
17:44:22 14:43:25.362363 run-command.c:627       trace: run\_command: 'rev-list' '--objects' '--stdin' '--not' '--all' '--quiet'
17:44:33 14:43:36.134600 run-command.c:627       trace: run\_command: 'rev-list' '--objects' '--stdin' '--not' '--all' '--quiet'
17:44:37 14:43:40.907788 git.c:344               trace: built-in: git 'rev-list' '--objects' '--stdin' '--not' '--all' '--quiet'
17:44:43 14:43:46.832265 run-command.c:1470      run\_processes\_parallel: preparing to run up to 1 tasks
17:44:43 14:43:46.832285 run-command.c:1502      run\_processes\_parallel: done
17:44:43 14:43:46.834911 run-command.c:627       trace: run\_command: 'gc' '--auto' '--quiet'
17:44:48 14:43:51.602346 git.c:344               trace: built-in: git 'rev-list' '--objects' '--stdin' '--not' '--all' '--quiet'
17:44:54 14:43:57.517547 run-command.c:1470      run\_processes\_parallel: preparing to run up to 1 tasks
17:44:54 14:43:57.517566 run-command.c:1502      run\_processes\_parallel: done
17:44:54 14:43:57.519818 run-command.c:627       trace: run\_command: 'gc' '--auto' '--quiet'
17:44:59 14:44:02.398842 git.c:344               trace: built-in: git 'gc' '--auto' '--quiet'
17:45:05 14:44:08.272641 git.c:344               trace: built-in: git 'gc' '--auto' '--quiet'
18:22:47 Build was aborted

Bedste reference