mb14
mb14

Reputation: 22596

How to disable to git delta compression when garbage collecting

I'm trying to run git gc on a repo but it fails because it run out of memory at the delta compression phase. I assume it's because some object are too big. Is there a way to avoid this memory problem (or disable the compression) ?

Upvotes: 2

Views: 1128

Answers (1)

VonC
VonC

Reputation: 1324278

You can test the settings of "Stopping a git gc --aggressive, is that a bad thing?"

git config pack.threads 1
git config pack.deltaCacheSize 1
git config core.packedGitWindowSize 16m
git config core.packedGitLimit 128m
git config pack.windowMemory 512m

Followed by:

git gc --aggressive

Check also, if you have a Git2.0+ (so not a git for Windows, limited to 1.9.5), my answer:

git gc --aggressive --depth=x

(try different values from the default 250 one)

Update May 2017: Git 2.13.x/2.14 (Q3 2017) will increase core.packedGitLimit considerable (up to 32 GiB!).
See "fatal: early EOF fatal: index-pack failed".

Upvotes: 2

Related Questions