(Incidentally I guess that either your repository is very large or these are machines with little memory - these values seem very low to me.)įor what it's worth, when getting malloc failures on repacking very large repositories in the past, I've also changed the values of core.packedgitwindowsize, core.packedgitlimit, ltacachesize, ltacachesize, pack.window and pack. You may want to do the same on your local repository. So, you should log in to the remote, change into the repository and do: git config pack.windowMemory 10m Fortunately, you can set config options that will reduce the amount of memory needed for repacking in both repositories - these essentially make the command line parameters that you added into the default options when repacking.
![git repack git repack](https://miro.medium.com/max/1400/1*iZEPynhZQVbIY16HVvQquQ.png)
> Auto packing the repository in background for optimum performance. Your solution has got you a working copy locally and remotely, but will cause problems again when the remote repository decides to repack itself again. What happened was: > git commit -m history commit. :~/repos/articles$ git repack -a -d -window-memory 10m -max-pack-size 100m
Git repack how to#
But instead of repacking the repository it describes how to use the "git pack-objects" command. To handle this error I have tried to repack the original repository (according to this forum post). Remote: aborting due to possible repository corruption on the remote side. Remote: fatal: Out of memory, malloc failedĮrror: git upload-pack: git-pack-objects died with error.įatal: git upload-pack: aborting due to possible repository corruption on the remote side. > Another interesting thing is, the loosenunusedpackedobjects() > function is being called twice because the function loads all packs > files, via getallpacks(), which will return the. Remote: warning: suboptimal pack - out of memory But in this > case, those promisor objects are in a pack which won't be deleted, so > they should not be included.
![git repack git repack](https://image.slidesharecdn.com/understanding-git-final-150918120830-lva1-app6892/95/understanding-git-goto-london-2015-24-638.jpg)
Initialized empty Git repository in /home/hemi/Skrivebord/articles/.git/ When I try to clone an existing repository from the server I get the following error :$ git clone ssh:// /home/hemi/repos/articles I have a git repository residing on a server with limited memory. Remove all old packfiles when doing 'git repack -a -d' blob commitdiff raw diff to current: : Junio C Hamano: Merge branch 'master' blob commitdiff raw diff to current: : Ralf Baechle: git-repack: Fix variable name: blob commitdiff raw diff to current: : Junio C Hamano: GIT 0.99.9h v0.99.9h v1.