From: Dmitry Potapov Date: Mon, 09 Aug 2010 21:28:17 GMT Subject: Re: Excessive mmap [was Git server eats all memory] Message-ID: In-Reply-To: On Mon, Aug 09, 2010 at 12:50:30PM -0400, Avery Pennarun wrote: > > On the other hand, perhaps a more important question is: why does git > feel like it needs to generate entirely new packs for each person > doing a clone on your system?  Shouldn't it be reusing existing ones > and just streaming them straight out to the recipient? Git cannot send the whole pack, in general, because it sends only those objects that are requested by the client. So, except the initial cloning, it is never the whole pack. Moreover, even during the initial cloning, it may not be the whole, but only visible objects from it. So, git has to generate a new pack for every clone operation. But the generated pack should reuse deltas from the initial pack, so it should not a very expensive operation. Dmitry