Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Broken Repository

Update

since nothing was really working, i gave in and fired rm -rf .gitmaybe a bit drastic and i am loosing the whole commit history, but i have to finish the project. In this state i wasn't able to commit anything. I saved some copies and will have a deeper look trying to understand what has happpened


git checkout 5b001a2is working, but the error persists

git status 
error: inflate: data stream error (incorrect header check)
fatal: loose object a3ee52c77080e851a4d4b2f1eea34246e85cb949 (stored in .git/objects/a3/ee52c77080e851a4d4b2f1eea34246e85cb949) is corrupt

Hi all,

i am not really sure when and what kind of BS i've done, but my local repository is broken.

git status 
error: inflate: data stream error (incorrect header check)
fatal: loose object a3ee52c77080e851a4d4b2f1eea34246e85cb949 (stored in .git/objects/a3/ee52c77080e851a4d4b2f1eea34246e85cb949) is corrupt

I've tried to verify the connectivity and validity of the objects with git fsck --full but doesn't really helps me.

Checking object directories: 100% (256/256), done.
error: inflate: data stream error (incorrect header check)
error: unable to unpack a3ee52c77080e851a4d4b2f1eea34246e85cb949 header
error: inflate: data stream error (incorrect header check)
error: inflate: data stream error (incorrect header check)
fatal: loose object a3ee52c77080e851a4d4b2f1eea34246e85cb949 (stored in .git/objects/a3/ee52c77080e851a4d4b2f1eea34246e85cb949) is corrupt

Next i tried git log as recommended on Stackoverflow

git log --oneline --decorate --all |head -n 8
4efe042 (HEAD, master) deleted
5b001a2 store and read back data working

So, i really don't know what to do or where to go from here. The suggestions given in the thread i've linked above, do not help also.

Thank you in advance for your help!

@Pfenya

This comment has been minimized.

Copy link

Pfenya commented Jan 12, 2016

I would guess you looked at these, too, but here are two more threads on this issue with different approaches that worked:
http://stackoverflow.com/questions/4254389/git-corrupt-loose-object
http://stackoverflow.com/questions/12571557/fixing-a-corrupt-loose-object-as-a-commit-in-git

@florianbachmann

This comment has been minimized.

Copy link

florianbachmann commented Jan 12, 2016

probier doch mal (im aktuellen git ordner)
% rm -f .git/objects/a3/ee52c77080e851a4d4b2f1eea34246e85cb949
% git fsck --full

und dann solange rm -r bis alles gut ist.

im zweifel wenn du nichts locales zu verlieren hast
lösch doch alles und mach ein neues git clone,
YOLO

@sebastianbachmann

This comment has been minimized.

Copy link
Owner Author

sebastianbachmann commented Jan 12, 2016

danke @florianbachmann

rm -f .git/objects/a3/ee52c77080e851a4d4b2f1eea34246e85cb949

git fsck --full
Checking object directories: 100% (256/256), done.
broken link from    tree 5265adc84c2e73716c9ce1bbf61964a1b00d5793
              to    blob a3ee52c77080e851a4d4b2f1eea34246e85cb949
dangling blob 4900ded21f175283191bf4484271b300993b289b
dangling blob 6c88df20a7e0250788995cc83e7fc1188c3f01e4
dangling blob ba68a8e76d9aa4d7e677af804a5b0fef3d7682d6
dangling blob 0a612ff1d8f22906b0243e6d58b76f205e17c193
dangling blob 3e112c4190c0d95b39ffa918ef6f7b10719aaabd
dangling blob 4539ece869fedcabd076e1cd9ab9e15ec87c656e
dangling blob 6b191598e9221a922f3d7f0f79be9c4cca30dbb7
dangling blob dbd16b1947d1bd15f738831d28d451744188e83f
dangling blob 1bea20f959a607a6fdf63f18043500b7d556195c
dangling blob 4db29a9e4f71847cd4a5bc54eb891f6abe16a31f
dangling blob d912f9d76b5fbbc7a42fecd973df23d39d3c367e
dangling blob f15a07cf745872f5215f759e8a22b22e94dff12c
dangling blob 65c35a46d544729fe92d11432cee4f36ecf35f0b
dangling blob 7df39eeea6e7cb3e0c1e8b62e7595d082621b942
dangling blob 8f330f025b3ba65c1ac1f584507b567a586dd672
dangling blob a2e30ece0beca79c417bda85eaf99810836d6ca2
dangling blob cbd364276178408e3260fdbc559513eb75363756
dangling blob d68b260547bf44250b32cb549e8d5b886a7ed733
dangling blob e7639bcc502daa2d05a513f8835aa0cfb432f3f6
dangling blob f4d3bfa575b1376f46073e5125b4c5c5972e1bd5
dangling blob 118c98f7461bf98b2bc7e061150d8021121ad277
dangling blob b77c57e2bba10092523096bf439c4123b87603a5
dangling blob cf147b4fd2bc5f1ed63a78580264fbd525de80e4
dangling blob 43c54761a24d79c3a3bdea5c6adb581fc856e3dd
dangling blob 622d7863b12490e4848ab5dce98091927a0653cb
dangling blob 757595d6674188def1759eb8713ed3e927af7264
dangling blob 870d4fe6fecc2f1bd75479f47bfb337e7afbcaf9
dangling blob 8f5d95335b6de6d7b5848dab7a168e50a4c7737a
dangling blob 8d9efa4d50be0b8eb35e7cd2b37d20028970d087
dangling blob a1bedd6432af29af81baa07e233d25800e9a7cc5
missing blob a3ee52c77080e851a4d4b2f1eea34246e85cb949
dangling blob c0c68fb0c3761f5a77dcd60728c209c5aab1c91e
dangling blob c796901b987afb7bc10c84bc9f16703887f7fdf6
dangling blob caee8807122818ac8b2e65dbdba62f4050d3df4a
dangling blob d886060707c92379bfcb8efe0991e8c2bfd17d2f
dangling blob 03bf57eaca95e5493ddd04f0289497490d8d77ec
dangling blob 1117881c603cce2359367cb3208c8b3ccbd4d7c6
dangling blob 591f5778afa823cdb9a1f49bed708f3bdbd80ac1
dangling blob 774f78113332dbb896e0296b7c00529b1b65af51
dangling blob 90b77fcbb3451c34efad12793140af74b3b66e69
dangling blob ac4f350b9508580aefab64a7885cbf13c9810136
dangling blob b2079e20518ea98974198a711c4cab91d69e8e95
dangling blob b937ddf3d271b6513b67d6de4bc15df51e8e3969
dangling blob e74f368585f4fe092a772c6f1a926105eb240824
git status 
fatal: unable to read a3ee52c77080e851a4d4b2f1eea34246e85cb949

Ich hatte das Repo nur lokal, neu klonen ist also leider nicht.

@sebastianbachmann

This comment has been minimized.

Copy link
Owner Author

sebastianbachmann commented Jan 12, 2016

danke für die Links @Pfenya da schau ich morgen mal drüber

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.