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

Re: Periodic hang during git index-pack

From
Jeff King <peff@peff.net>
Date
Dec 19, 2018, 23:22 UTC
Message-ID
<20181219232200.GB21283@sigill.intra.peff.net>
In-Reply-To
<CALjAwxiB1uDfg4iPFjh2dNibEZa5mJ0RwhCzt0R2b87NTVqWfA@mail.gmail.com>
On Wed, Dec 19, 2018 at 10:59:30PM +0000, Sitsofe Wheeler wrote:
Show 11 quoted lines
> While using trying to use git to clone a remote repository git
> index-pack occasionally goes on to hang:
> [...]
> Looking at where it is stuck, git is doing read of a pipe:
> 
> #0  0x00007fd1b845034e in __libc_read (fd=fd@entry=0,
> buf=buf@entry=0x55ab81e19d40 <input_buffer>, nbytes=nbytes@entry=4096)
>     at ../sysdeps/unix/sysv/linux/read.c:27
> #1  0x000055ab81b51b23 in read (__nbytes=4096, __buf=0x55ab81e19d40
> <input_buffer>, __fd=0)
>     at /usr/include/x86_64-linux-gnu/bits/unistd.h:44

Index-pack is reading the pack on stdin, so it's expecting more bytes. Those bytes should be coming from the git-clone process, which is relaying the bytes from the other side.

Check the backtrace of git-clone to see why it isn't feeding more data (but note that it will generally have two threads -- one processing the data from the remote, and one wait()ing for index-pack to finish).

My guess, though, is that you'll find that git-clone is simply waiting on another pipe: the one from ssh.

-Peff
Previous: Sitsofe WheelerNext: Sitsofe Wheeler
Message 2 of 6 in “Periodic hang during git index-pack”
  1. Sitsofe WheelerDec 19, 2018
  2. Jeff KingDec 19, 2018
  3. Sitsofe WheelerDec 20, 2018
  4. Jeff KingDec 20, 2018
  5. Sitsofe WheelerDec 20, 2018
  6. Sitsofe WheelerFeb 3, 2019

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.