zekikez Posted July 29, 2014 Report Share Posted July 29, 2014 Hello, Whenever I execute the "emerge --sync" command it ends up giving me "git pull error in /usr/portage." Is there a solution to this problem? >>> Starting git pull... remote: Counting objects: 20916, done. remote: Compressing objects: 100% (17257/17257), done. remote: Total 20916 (delta 9827), reused 5201 (delta 3627) Receiving objects: 100% (20916/20916), 10.69 MiB | 416.00 KiB/s, done. Resolving deltas: 100% (9827/9827), done. error: Could not read 6e621e187d2d5d2e7c2ee4f78c96dfcfe7c47275 fatal: bad tree object 6e621e187d2d5d2e7c2ee4f78c96dfcfe7c47275 error: git://github.com/funtoo/ports-2012.git did not send all necessary objects !!! git pull error in /usr/portage. Thanks for any help, Steven Sinakhot Link to comment Share on other sites More sharing options...
0 sputnik Posted July 29, 2014 Report Share Posted July 29, 2014 Sounds like your portage directory is broken. Not to worry, happens to everybody now & then, simply rename /usr/portage to something else and follow the instructions here: http://www.funtoo.org/Installing_Portage_From_Snapshot Link to comment Share on other sites More sharing options...
0 zekikez Posted July 29, 2014 Author Report Share Posted July 29, 2014 Yup, this fixed my issue. Thank you! Link to comment Share on other sites More sharing options...
0 jmmc Posted July 31, 2014 Report Share Posted July 31, 2014 Ah, right, there we go. Thanks sputnik. Fyi, I just hit this too (on a box I just powered up after it being off for a week and having a clean sync prior to my work trip)...which was curious...hmmm...? Np, though - this'll work.Been a while since I had to manually restore a tree ("way back" in my Gentoo days lol). Link to comment Share on other sites More sharing options...
0 dantrell Posted August 1, 2014 Report Share Posted August 1, 2014 Just for the record, this will be looked into over at FL-1429 and hopefully a proper fix will be found. Link to comment Share on other sites More sharing options...
0 jmmc Posted August 1, 2014 Report Share Posted August 1, 2014 Thanks dantrell, much appreciated! Link to comment Share on other sites More sharing options...
0 dantrell Posted August 2, 2014 Report Share Posted August 2, 2014 This particular issue has been resolved. The recommended method for addressing this is to try Plan A (likely too fail) and then Plan B (not likely to fail) mentioned on FL-1429. Link to comment Share on other sites More sharing options...
0 stifler83 Posted August 3, 2014 Report Share Posted August 3, 2014 Hi guys, i have this problem: >>> Starting git pull... remote: Counting objects: 6866, done. remote: Compressing objects: 100% (6292/6292), done. remote: Total 6866 (delta 3429), reused 1030 (delta 565) Receiving objects: 100% (6866/6866), 11.01 MiB | 717.00 KiB/s, done. Resolving deltas: 100% (3429/3429), done. fatal: missing blob object 'cf51e2c54044a27623dcbf58fc388ff504dca323' error: git://github.com/funtoo/ports-2012.git did not send all necessary objects !!! git pull error in /usr/portage. I followed the instructions here: https://bugs.funtoo.org/browse/FL-1429 Link to comment Share on other sites More sharing options...
0 dantrell Posted August 3, 2014 Report Share Posted August 3, 2014 Hi guys, i have this problem: >>> Starting git pull... remote: Counting objects: 6866, done. remote: Compressing objects: 100% (6292/6292), done. remote: Total 6866 (delta 3429), reused 1030 (delta 565) Receiving objects: 100% (6866/6866), 11.01 MiB | 717.00 KiB/s, done. Resolving deltas: 100% (3429/3429), done. fatal: missing blob object 'cf51e2c54044a27623dcbf58fc388ff504dca323' error: git://github.com/funtoo/ports-2012.git did not send all necessary objects !!! git pull error in /usr/portage. I followed the instructions here: https://bugs.funtoo.org/browse/FL-1429 The idea is to follow Plan A to F (D to F not recommended unless you know what you are doing to prevent undesired data loss) in order until something worked. Plan C will work 100% but restoring *all* of the missing blobs as in Plan B is the cleanest solution. If you are willing to hop on IRC and spend some time, I can walk you through it. Even better if you can get me a copy of your corrupt git repository. I'm going to see about writing a simple tool to automate the repair process shown in Plan B. This would be the best solution. Link to comment Share on other sites More sharing options...
0 Eduard Nicodei Posted August 3, 2014 Report Share Posted August 3, 2014 I had the same problem (last sync was Jul 26). Out of curiosity, does anybody know why this happens? It seems odd that a git repository gets corrupted out of the blue. One of the design principles behind git is that it ensured data consistency. Is this therefore caused by improper handling of the repo by github? Or is it caused by something like a complex history rewrite (git push --force)? I'm asking because the comments on the bugtracker don't say anything about the underlying cause of this bug. Thanks in advance! edit: to fix, I first did a git status on /usr/portage, then simply copied /usr/portage/distfiles and /usr/portage/packages to a safe place, rm -rf /usr/portage/.git then did a emerge --sync and copied back distfiles and packages (basically plans D-F but also saving my package cache). Link to comment Share on other sites More sharing options...
0 dantrell Posted August 3, 2014 Report Share Posted August 3, 2014 I don't know what's causing this yet. Fixing it entirely is a bit involving and we would have to rule out hardware/network errors or any other underlying causes of corruption and after replacing all the culripts (trees included), everyone might sitll have to acquire a clean tree. In the meantime, I have replaced the manual steps in Plan B with a script that automates the process. To the best of my knowledge it works but requests may occasionaly be rate limited by GitHub (in which case you'll have to wait a hour or so before trying again). Link to comment Share on other sites More sharing options...
Question
zekikez
Hello,
Whenever I execute the "emerge --sync" command it ends up giving me
"git pull error in /usr/portage." Is there a solution to this problem?
>>> Starting git pull...
remote: Counting objects: 20916, done.
remote: Compressing objects: 100% (17257/17257), done.
remote: Total 20916 (delta 9827), reused 5201 (delta 3627)
Receiving objects: 100% (20916/20916), 10.69 MiB | 416.00 KiB/s, done.
Resolving deltas: 100% (9827/9827), done.
error: Could not read 6e621e187d2d5d2e7c2ee4f78c96dfcfe7c47275
fatal: bad tree object 6e621e187d2d5d2e7c2ee4f78c96dfcfe7c47275
error: git://github.com/funtoo/ports-2012.git did not send all necessary objects
!!! git pull error in /usr/portage.
Thanks for any help,
Steven Sinakhot
Link to comment
Share on other sites
10 answers to this question
Recommended Posts