[Cialug] git memory issue
Todd Walton
tdwalton at gmail.com
Mon Mar 28 18:22:30 UTC 2022
On Mon, Mar 28, 2022 at 10:08 AM L. V. Lammert <lvl at omnitec.net> wrote:
> Cleaned up a repo and added a new remote on an older server (v1.6.4.7),
> but pushing thows a memory error:
>
> $ git push--set-upstream master master
> Enumerating objects: 1502, done.
> Counting objects: 100% (1502/1502), done.
> Delta compression using up to 2 threads
> Compressing objects: 100% (1496/1496), done.
> fatal: Out of memory, malloc failed
>
> The problem seems to be that newer versions of git (v 2.25.2) do not honor
> older memory parameters:
>
> [core]
> packedGitLimit = 128m
> packedGitWindowSize = 128m
>
> [pack]
> deltaCacheSize = 128m
> packSizeLimit = 128m
> windowMemory = 128m
>
> [http]
> postbuffer = 5m
>
> Don't suppose anyone knows how to limit memory usage with 2.26?
>
It looks to me like all those options still exist. The documentation still
lists them: https://git-scm.com/docs/git-config
Also:
❯ git clone https://github.com/git/git
❯ cd git/
❯ rg packedGitLimit .
./t/t5301-sliding-window.sh: git config core.packedGitLimit 512 &&
./t/t5301-sliding-window.sh: git config core.packedGitLimit 512 &&
./t/t5301-sliding-window.sh: git config --unset core.packedGitLimit &&
./packfile.c: "pack_report: core.packedGitLimit = %10" SZ_FMT "\n",
./Documentation/config/core.txt:core.packedGitLimit::
❯ git checkout tags/v2.26.3 -b v2.26.3
❯ rg packedGitLimit .
./t/t5301-sliding-window.sh: git config core.packedGitLimit 512 &&
./t/t5301-sliding-window.sh: git config core.packedGitLimit 512 &&
./t/t5301-sliding-window.sh: git config --unset core.packedGitLimit &&
./packfile.c: "pack_report: core.packedGitLimit = %10" SZ_FMT "\n",
./Documentation/config/core.txt:core.packedGitLimit::
❯ git checkout tags/v1.6.4.5 -b v1.6.4.5
❯ rg packedGitLimit .
./t/t5301-sliding-window.sh: git config core.packedGitLimit 512 &&
./t/t5301-sliding-window.sh: git config core.packedGitLimit 512 &&
./t/t5301-sliding-window.sh: git config --unset core.packedGitLimit &&
./sha1_file.c: "pack_report: core.packedGitLimit = %10" SZ_FMT "\n",
./contrib/completion/git-completion.bash: core.packedGitLimit
./Documentation/config.txt:core.packedGitLimit::
So, it looks like not much has changed in that regard.
--
Todd
More information about the Cialug
mailing list