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

Re: Help with "fatal: unable to read ...." error during GC?

From
Jeff King <peff@peff.net>
Date
Aug 8, 2018, 18:24 UTC
Message-ID
<20180808182436.GA19096@sigill.intra.peff.net>
In-Reply-To
<b247434b62ccd30f32adbebb83fa6ea12b51b6ff.camel@mad-scientist.net>
On Wed, Aug 08, 2018 at 01:35:30PM -0400, Paul Smith wrote:
> Thanks for the note!  Unhappily for me none of these operations seem to
> find any actionable problems...
> [...]
Drat.

One other option is that it _could_ be related to the "old unreachable objects that are reachable from recent unreachable objects should be kept" code. That's supposed to quietly ignore broken links in unreachable objects, but there could be a bug.

Let's narrow it down first and make sure we're dying where I expect. Can you try:

  GIT_TRACE=1 git gc
and confirm the program running when the fatal error is produced?

From what you've shown it's going to be git-repack, but what I'm not clear on is whether it is repack itself that is complaining, or the pack-objects process it spawns. I'd guess the latter.

If so, can you try running it under gdb and getting a stack trace? Something like:

  gdb git
  [and then inside gdb...]
  set args pack-objects --all --reflog --indexed-objects foo </dev/null
  break die
  run
  bt

That might give us a clue where the broken object reference is coming from.

-Peff
Previous: Paul SmithNext: Paul Smith
Message 4 of 13 in “Help with "fatal: unable to read ...." error during GC?”
  1. Paul SmithAug 8, 2018
  2. Jeff KingAug 8, 2018
  3. Paul SmithAug 8, 2018
  4. Jeff KingAug 8, 2018
  5. Paul SmithAug 8, 2018
  6. Paul SmithAug 9, 2018
  7. Jeff KingAug 9, 2018
  8. Paul SmithAug 11, 2018
  9. Jeff KingAug 11, 2018
  10. Jeff KingAug 11, 2018
  11. Duy NguyenAug 11, 2018
  12. Jeff KingAug 11, 2018
  13. Duy NguyenAug 12, 2018

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.