Slow git clone and fetch

git

I setuped gitosis on a linux server following this tutorial:

http://scie.nti.st/2007/11/14/hosting-git-repositories-the-easy-and-secure-way

We are using git on our windows machines with TortoiseGit and msysgit.

Pushing changes to the server is pretty fast, but when we want to clone or fetch changes from the remote server, it begins really fast (800k/s) and then drop pretty fast to around 3 to 30k/s and it can take forever to update. git-pull for small update is fast, but as soon as we have to download something of more than a few MB, it is slow.

We are switching from SVN to git and this is holding us back from using git full time.

Thanks!

Best Answer

Like you were able to identify, this is a client issue, not the server fault.

If you want, you can configure TortoiseGit to use Putty's plink instead of its custom implementation.

Then you can customize the default settings using Putty.

In Putty "Default Settings", enable the following:

  1. SSH -> Auth: "Allow agent forwarding" (I believe this is the one that changes "everything")
  2. SSH -> "Enable Compression"
  3. Session -> Select "Default Settings" -> Save

For me, this resulted in going from 143.00 KiB/s to 4.50 MiB/s

Hope this helps.