Reputation: 5865
I have 5 submodules and a git submodule update
takes 6-8 seconds. The same git submodule update
command on the same repo in ubuntu 13.10 takes 0.4 seconds.
In order to resolve this, I've tried everything listed in these two questions:
Msysgit bash is horrendously slow in Windows 7
Git/Bash is extremely slow in Windows 7 x64
I've performed the following:
export PS1='$'
in git bashgit config --global core.preloadindex true
git config --global core.fscache true
git config --global gc.auto 256
I'm out of ideas and figured I'd ask if anyone has had this same issue, specifically with submodule updates. Git performance otherwise is acceptable when implementing the above list of changes. I'm beginning to think the implementation of the git command in windows is actually at fault.
Upvotes: 2
Views: 1408
Reputation: 5865
The culprit was McAfee virus scanner. Only took me 2.5 years to figure it out. In troubleshooting a different issue, our IT team removed it entirely (I'm amazed they actually did this) and I took the opportunity to test this out. Submodule updates are 4x faster and compiling is 2x faster.
Upvotes: 0
Reputation: 1490
Tried all of the above but after digging multiple hours I finally found a solution for an old and a brand new Windows box running msysgit 1.9.x.
Try setting %LOGONSERVER%
to a "valid" value like \\%COMPUTERNAME%
. In fact, setting it to any value other than empty yielded a stable and normal network performance for Git+SSH on both Windows boxes.
Running a super simple:
git ls-remote git@gitlab...
Old Windows: 27 s -> 0.8 s
New Windows: 7 s -> 0.8 s
Yep, that's 27 s for one request.
Both boxes are Jenkins slaves run by Windows Task scheduler. Performance normalized after logging on using RDP making this really tricky to debug. Jenkins' "System Information" page and its Environment Variables dump finally gave it away.
Upvotes: 1