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

Re: Long clone time after "done."

From
Jeff King <peff@peff.net>
Date
Nov 8, 2012, 22:33 UTC
Message-ID
<20121108223319.GA11734@sigill.intra.peff.net>
In-Reply-To
<CAMJd5ATX5Ru9Orp2t3p39q7tsNRfGjqDYGnf4-9QYNSTpQ-YuA@mail.gmail.com>
On Thu, Nov 08, 2012 at 04:16:59PM -0600, Uri Moszkowicz wrote:
Show 6 quoted lines
> I ran "git cat-file commit some-tag" for every tag. They seem to be
> roughly uniformly distributed between 0s and 2s and about 2/3 of the
> time seems to be system. My disk is mounted over NFS so I tried on the
> local disk and it didn't make a difference.
> 
> I have only one 1.97GB pack. I ran "git gc --aggressive" before.

Ah. NFS. That is almost certainly the source of the problem. Git will aggressively mmap. I would not be surprised to find that RHEL4's NFS implementation is not particularly fast at mmap-ing 2G files, and is spending a bunch of time in the kernel servicing the requests.

Aside from upgrading your OS or getting off of NFS, I don't have a lot of advice. The performance characteristics you are seeing are so grossly off of what is normal that using git is probably going to be painful. Your 2s cat-files should be more like .002s. I don't think there's anything for git to fix here.

You could try building with NO_MMAP, which will emulate it with pread. That might fare better under your NFS implementation. Or it might be just as bad.

-Peff
Previous: Uri MoszkowiczNext: Uri Moszkowicz
Message 11 of 13 in “Long clone time after "done."”
  1. Uri MoszkowiczOct 23, 2012
  2. Nguyen Thai Ngoc DuyOct 24, 2012
  3. Uri MoszkowiczOct 24, 2012
  4. Uri MoszkowiczNov 7, 2012
  5. Jeff KingNov 8, 2012
  6. Uri MoszkowiczNov 8, 2012
  7. Jeff KingNov 8, 2012
  8. Uri MoszkowiczNov 8, 2012
  9. Jeff KingNov 8, 2012
  10. Uri MoszkowiczNov 8, 2012
  11. Jeff KingNov 8, 2012
  12. Uri MoszkowiczNov 8, 2012
  13. Uri MoszkowiczNov 26, 2012

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.