From: Duy Nguyen <pclouds@gmail.com>
To: Martin Fick <mfick@codeaurora.org>
Cc: Jeff King <peff@peff.net>, Git Mailing List <git@vger.kernel.org>
Subject: Re: pack corruption post-mortem
Date: Thu, 17 Oct 2013 08:06:50 +0700 [thread overview]
Message-ID: <CACsJy8ArdCrqn58wnx9c6wx148CfnQrWPfuxH5D7s1bvwr=cjQ@mail.gmail.com> (raw)
In-Reply-To: <201310160941.16904.mfick@codeaurora.org>
On Wed, Oct 16, 2013 at 10:41 PM, Martin Fick <mfick@codeaurora.org> wrote:
>> and then running "git index-pack tmp.pack" in the
>> debugger (stop at unpack_raw_entry). Doing this, I found
>> that there were 3 bytes of header (and the header itself
>> had a sane type and size). So I stripped those off with:
>>
>> dd if=object of=zlib bs=1 skip=3
>
> This too feels like something we should be able to do with a
> plumbing command eventually?
>
> git zlib-extract
Not an official plumbing, but I faced similar problems with pack v4. I
needed to verify that the output is correct and low level decoding
like this is generally a good thing to start with. So I wrote
test-dump [1] that can take an offset, a format and try to decode it.
It does not support zlib inflation yet, but adding one should be easy.
And because this is just a test program we don't really need to think
hard before adding something.
[1] http://article.gmane.org/gmane.comp.version-control.git/235388
--
Duy
next prev parent reply other threads:[~2013-10-17 1:07 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-10-16 8:34 pack corruption post-mortem Jeff King
2013-10-16 8:59 ` Duy Nguyen
2013-10-16 15:41 ` Martin Fick
2013-10-17 0:35 ` Jeff King
2013-10-17 15:47 ` Junio C Hamano
2013-10-25 7:55 ` Jeff King
2013-10-17 1:06 ` Duy Nguyen [this message]
2013-10-19 10:32 ` Duy Nguyen
2013-10-19 14:41 ` Nicolas Pitre
2013-10-19 19:17 ` Shawn Pearce
2013-10-20 20:56 ` Nicolas Pitre
2013-10-20 4:44 ` Duy Nguyen
2013-10-20 21:08 ` Nicolas Pitre
2015-04-01 21:08 ` [PATCH] howto: document more tools for recovery corruption Jeff King
2015-04-01 22:21 ` Junio C Hamano
2015-04-02 0:49 ` Jeff King
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: http://vger.kernel.org/majordomo-info.html
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CACsJy8ArdCrqn58wnx9c6wx148CfnQrWPfuxH5D7s1bvwr=cjQ@mail.gmail.com' \
--to=pclouds@gmail.com \
--cc=git@vger.kernel.org \
--cc=mfick@codeaurora.org \
--cc=peff@peff.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://80x24.org/mirrors/git.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).