{"thread":{"id":"13888","subject":"git-reflog infinite loop","startedAt":"2008-06-10T17:44:50Z","lastAt":"2008-06-11T18:58:23Z","messageCount":5,"participants":["Pascal Obry","Jeff King"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"79372","messageId":"484EBD92.8040603@obry.net","threadId":"13888","inReplyTo":null,"subject":"git-reflog infinite loop","fromName":"Pascal Obry","fromEmail":"pascal@obry.net","sentAt":"2008-06-10T17:44:50Z","receivedAt":"2008-06-10T17:44:50Z","isPatch":false,"sender":{"key":"pascal@obry.net","avatar":"https://avatars.githubusercontent.com/u/467069?v=4"},"body":"\nIn one of my repository, \"git gc\" will never terminate.\n\nI have traced to the underlying call git-reflog:\n\n    $ git-reflog expire --all\n\nIt seems to heat a good amount of heap memory and will keep running \nusing 100% of CPU.\n\nIs that a known issue?\n\nThanks,\nPascal.\n\n-- \n\n--|------------------------------------------------------\n--| Pascal Obry                           Team-Ada Member\n--| 45, rue Gabriel Peri - 78114 Magny Les Hameaux FRANCE\n--|------------------------------------------------------\n--|              http://www.obry.net\n--| \"The best way to travel is by means of imagination\"\n--|\n--| gpg --keyserver wwwkeys.pgp.net --recv-key C1082595\n"},{"id":"79426","messageId":"20080611034718.GB7198@sigill.intra.peff.net","threadId":"13888","inReplyTo":"484EBD92.8040603@obry.net","subject":"Re: git-reflog infinite loop","fromName":"Jeff King","fromEmail":"peff@peff.net","sentAt":"2008-06-11T03:47:18Z","receivedAt":"2008-06-11T03:47:18Z","isPatch":false,"sender":{"key":"peff@peff.net","avatar":"https://avatars.githubusercontent.com/u/45925?v=4"},"body":"On Tue, Jun 10, 2008 at 07:44:50PM +0200, Pascal Obry wrote:\n\n> In one of my repository, \"git gc\" will never terminate.\n>\n> I have traced to the underlying call git-reflog:\n>\n>    $ git-reflog expire --all\n>\n> It seems to heat a good amount of heap memory and will keep running using \n> 100% of CPU.\n>\n> Is that a known issue?\n\nI can't reproduce here, so presumably it is some condition in your\nrepository; can you make a tarball of your .git directory available?\n\n-Peff\n"},{"id":"79430","messageId":"484F66A5.6070205@obry.net","threadId":"13888","inReplyTo":"20080611034718.GB7198@sigill.intra.peff.net","subject":"Re: git-reflog infinite loop","fromName":"Pascal Obry","fromEmail":"pascal@obry.net","sentAt":"2008-06-11T05:46:13Z","receivedAt":"2008-06-11T05:46:13Z","isPatch":false,"sender":{"key":"pascal@obry.net","avatar":"https://avatars.githubusercontent.com/u/467069?v=4"},"body":"Jeff King a écrit :\n> I can't reproduce here, so presumably it is some condition in your\n> repository;\n\nYes, I have this problem on a single repository and no problem on the \nothers (~10).\n\n> can you make a tarball of your .git directory available?\n\nNo I can't :(\n\nIs there some git-reflog options I can try to help finding this problem?\n\nThanks,\nPascal.\n\n-- \n\n--|------------------------------------------------------\n--| Pascal Obry                           Team-Ada Member\n--| 45, rue Gabriel Peri - 78114 Magny Les Hameaux FRANCE\n--|------------------------------------------------------\n--|              http://www.obry.net\n--| \"The best way to travel is by means of imagination\"\n--|\n--| gpg --keyserver wwwkeys.pgp.net --recv-key C1082595\n"},{"id":"79436","messageId":"20080611070326.GA9980@sigill.intra.peff.net","threadId":"13888","inReplyTo":"484F66A5.6070205@obry.net","subject":"Re: git-reflog infinite loop","fromName":"Jeff King","fromEmail":"peff@peff.net","sentAt":"2008-06-11T07:03:26Z","receivedAt":"2008-06-11T07:03:26Z","isPatch":false,"sender":{"key":"peff@peff.net","avatar":"https://avatars.githubusercontent.com/u/45925?v=4"},"body":"On Wed, Jun 11, 2008 at 07:46:13AM +0200, Pascal Obry wrote:\n\n>> can you make a tarball of your .git directory available?\n>\n> No I can't :(\n>\n> Is there some git-reflog options I can try to help finding this problem?\n\nNot that I can think of offhand. If I had gotten a copy of the\nrepository, I would have run it under strace and/or gdb to see what it\nwas doing while it hung. If you're comfortable with running a debugger,\nyou might be able to point us to the right part of the code (I'm\nassuming there is an infinite loop in there somewhere).\n\n-Peff\n"},{"id":"79481","messageId":"4850204F.50401@obry.net","threadId":"13888","inReplyTo":"20080611034718.GB7198@sigill.intra.peff.net","subject":"Re: git-reflog infinite loop","fromName":"Pascal Obry","fromEmail":"pascal@obry.net","sentAt":"2008-06-11T18:58:23Z","receivedAt":"2008-06-11T18:58:23Z","isPatch":false,"sender":{"key":"pascal@obry.net","avatar":"https://avatars.githubusercontent.com/u/467069?v=4"},"body":"Jeff King a écrit :\n> I can't reproduce here, so presumably it is some condition in your\n> repository; can you make a tarball of your .git directory available?\n\nOk, mystery solved.\n\nThe problem was that the repository had been imported using git-svn and \ncontained something like 86000 reflog entries in \n.git/logs/refs/remotes/pre/trunk.\n\nUsing the debugger I have seen that the loop was not endless... but very \nslow as there was many many reflog to process. Don't know if this is \nexpected or not though.\n\nTo fix that I have launched:\n\n    $ git-reflog expire --expire=10 --all\n\nIt has removed all the old reflogs dating from the git-svn initial \nimport lowering the number of enties in .git/logs/refs/remotes/pre/trunk \nto 0 :)\n\ngit gc is now working like a charm!\n\nPascal.\n\n-- \n\n--|------------------------------------------------------\n--| Pascal Obry                           Team-Ada Member\n--| 45, rue Gabriel Peri - 78114 Magny Les Hameaux FRANCE\n--|------------------------------------------------------\n--|              http://www.obry.net\n--| \"The best way to travel is by means of imagination\"\n--|\n--| gpg --keyserver wwwkeys.pgp.net --recv-key C1082595\n"}]}