相关疑难解决方法(0)

Git gc使用过多的内存,无法完成

最终更新和修复:这里的解决方案结果是两件事:使用Windows Git而不是Grag Borland 建议的 Cygwin Git ,以及Git配置设置pack.threads = 1gc.aggressiveWindow = 150.

我有一个大型的本地Git存储库,一个git svn cloneSVN存储库,大约有40,000次提交.我正试图git gc在这个存储库上运行,并且无处可去:

$ git gc --auto
Auto packing the repository for optimum performance. You may also
run "git gc" manually. See "git help gc" for more information.
Counting objects: 25966, done.
Compressing objects: 100% (25249/25249), done.
fatal: Out of memory, malloc failed (tried to allocate 426523986 bytes)
error: failed to run repack
Run Code Online (Sandbox Code Playgroud)

我正在使用4GB RAM的64位双核Win7机器上运行Cygwin中的Git 1.7.5.1.该.git目录目前略高于6.1GB.

我已经尝试过运行 …

git git-svn git-gc

35
推荐指数
3
解决办法
1万
查看次数

标签 统计

git ×1

git-gc ×1

git-svn ×1