git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: Git server eats all memory

From
Avery Pennarun <apenwarr@gmail.com>
Date
Aug 4, 2010, 20:12 UTC
Message-ID
<AANLkTimwy6GumHYSTo2je_hOUO80KEpx4_8z3iOoZyc0@mail.gmail.com>
In-Reply-To
<wesfwyupgrg.fsf@kanis.fr>

On Wed, Aug 4, 2010 at 10:57 AM, Ivan Kanis <expire-by-2010-08-09@kanis.fr> wrote:

Show 8 quoted lines
> I am running git 1.7.0.4 on Debian stable. I have compiled git from
> source. I am cloning using ssh.The client and the server are running
> the same version. The bare repository is 4.5G with various binary files,
> I have 6G of memory on my server.
>
> I am having problem with memory ballooning when receiving object
> from the server. The amount of memory used on the server seems to be same
> size as the object received.

Git works fine with huge repositories; it does not work fine at all with very large individual objects in a repository, and it does what you're experiencing. There are a few minor workarounds (like the repack command someone mentioned) that slightly reduce the symptoms, but the symptoms will crop up again eventually.

There's at least one project intended to solve this that people have linked to: http://caca.zoy.org/wiki/git-bigfiles

...but it's incomplete and it doesn't look like their repo has changed in some time.

I'm not aware of any workaround to this sort of thing other than "don't store large objects in git." You can split the big objects into a bunch of small objects, as bup does, but then you have to reassemble them all, which is inconvenient.

Sorry,
Avery
Previous: Ivan KanisNext: Ivan Kanis
Message 4 of 28 in “Git server eats all memory”
  1. Ivan KanisAug 4, 2010
  2. Matthieu MoyAug 4, 2010
  3. Ivan KanisAug 4, 2010
  4. Avery PennarunAug 4, 2010
  5. Ivan KanisAug 5, 2010
  6. Jared HanceAug 5, 2010
  7. Nguyen Thai Ngoc DuyAug 6, 2010
  8. Nguyen Thai Ngoc DuyAug 6, 2010
  9. Jakub NarebskiAug 6, 2010
  10. Ivan KanisAug 6, 2010
  11. Dmitry PotapovAug 7, 2010
  12. Excessive mmap [was Git server eats all memory]Ivan Kanis, Aug 9, 2010
  13. Dmitry PotapovAug 9, 2010
  14. Ivan KanisAug 9, 2010
  15. Avery PennarunAug 9, 2010
  16. Tomas CarneckyAug 9, 2010
  17. Avery PennarunAug 9, 2010
  18. Dmitry PotapovAug 9, 2010
  19. Ivan KanisAug 11, 2010
  20. Avery PennarunAug 11, 2010
  21. Duy NguyenJun 20, 2018
  22. Robin H. JohnsonAug 10, 2010
  23. Sverre RabbelierAug 10, 2010
  24. Sam VilainAug 11, 2010
  25. Ivan KanisAug 11, 2010
  26. Nguyen Thai Ngoc DuyAug 9, 2010
  27. Ivan KanisAug 9, 2010
  28. Dmitry PotapovAug 17, 2010

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.