{"thread":{"id":"21985","subject":"repo corruption - Egit's fault?","startedAt":"2009-12-18T18:06:49Z","lastAt":"2009-12-18T18:51:11Z","messageCount":4,"participants":["Eugene Sajine","Shawn O. Pearce"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"130081","messageId":"76c5b8580912181006p2aef9d2fj95bb4c8456d965b@mail.gmail.com","threadId":"21985","inReplyTo":null,"subject":"repo corruption - Egit's fault?","fromName":"Eugene Sajine","fromEmail":"euguess@gmail.com","sentAt":"2009-12-18T18:06:49Z","receivedAt":"2009-12-18T18:06:49Z","isPatch":false,"sender":{"key":"euguess@gmail.com","avatar":null},"body":"Hi,\n\nWe have imported a project from CVS. Then created a bare repo and\nplaced on the central server. From the server repos are served via git\nprotocol for push and pull operations (no SSH is involved for intranet\nset up)\nAfter this operations there were several extensive changes made (3\ncommits but they were pretty big) in development branch which were\nthen pushed to the server. So the branch was pushed too.\nAll changes and commits and pushes were performed under eclipse 3.5\nusing Egit plugin v0.5.\n\nAfter it I could not clone this repo from the server as it was giving\nme an error like this (I will shorten it up a bit using “…” as I have\nno way to copy paste):\n\n$git clone git://server/repo.git\nInitialized empty git…\nremote:counting…done\nremote:compressing…done\nremote: aborting due to possible repository corruption on the remote side.\nReceiving object: 100% …done\nResolving deltas: 100% …done\nerror: waitpid (async) failed\nfatal: error in sideband demultiplexer (I know right words to curse now;))\n\nWhen I’m looking at the bare repo in CGit  it shows me  Bad object:\nand object SHA-1 instead of  the tree.\n\nAs the only difference between this project and about 30 others was\nthat there was an additional branch pushed via Egit I suspect that\nthis is what screwed up things, but I ‘m not sure… I’m in progress of\ntesting it I don’t know if I will be able to reproduce.\n\nPlease, advise if this can be fixed and which options I have if it\nwill happen again (how to properly and quickly restore bare repo)\n\nThanks,\nEugene\n"},{"id":"130083","messageId":"20091218181613.GA10687@spearce.org","threadId":"21985","inReplyTo":"76c5b8580912181006p2aef9d2fj95bb4c8456d965b@mail.gmail.com","subject":"Re: repo corruption - Egit's fault?","fromName":"Shawn O. Pearce","fromEmail":"spearce@spearce.org","sentAt":"2009-12-18T18:16:13Z","receivedAt":"2009-12-18T18:16:13Z","isPatch":false,"sender":{"key":"spearce@spearce.org","avatar":"https://avatars.githubusercontent.com/u/34844?v=4"},"body":"Eugene Sajine <euguess@gmail.com> wrote:\n> When I???m looking at the bare repo in CGit ??it shows me ??Bad object:\n> and object SHA-1 instead of ??the tree.\n> \n> As the only difference between this project and about 30 others was\n> that there was an additional branch pushed via Egit I suspect that\n> this is what screwed up things, but I ???m not sure??? I???m in progress of\n> testing it I don???t know if I will be able to reproduce.\n\nIts a somewhat known problem, but thus far has only shown up in\ncontexts where I'm unable to get enough data to debug the problem.\n\n  https://bugs.eclipse.org/bugs/show_bug.cgi?id=286653\n\n> Please, advise if this can be fixed and which options I have if it\n> will happen again (how to properly and quickly restore bare repo)\n\nDelete the branch and repush it.  The bug is that EGit didn't push\nall of the objects needed by the branch.  If you put the missing\nobjects from the source client into the server repository, it'll\nbe fine.\n\nTo prevent this in the future, you can force a server to check during\npush by enabling receive.fsckObjects in the server repository's\nconfiguration file.  A broken EGit client will have the push\nrejected immediately.\n\n-- \nShawn.\n"},{"id":"130085","messageId":"76c5b8580912181030k56cb7dd7l811c0a0d4773d309@mail.gmail.com","threadId":"21985","inReplyTo":"20091218181613.GA10687@spearce.org","subject":"Re: repo corruption - Egit's fault?","fromName":"Eugene Sajine","fromEmail":"euguess@gmail.com","sentAt":"2009-12-18T18:30:45Z","receivedAt":"2009-12-18T18:30:45Z","isPatch":false,"sender":{"key":"euguess@gmail.com","avatar":null},"body":"> To prevent this in the future, you can force a server to check during\n> push by enabling receive.fsckObjects in the server repository's\n> configuration file.  A broken EGit client will have the push\n> rejected immediately.\n>\n> --\n> Shawn.\n>\n\nThank you for prompt answer, Shawn!\n\nThe problem is that as i'm maintaining multiple repos and their\nquantity will grow i would need to apply this setting site wide. Do\nyou know if i can specify this service for git daemon? It seems like\nin git deamon docs this service is not listed, but just in case the\ndocs are not up to date... I really don't want to set this up for\nevery repo manually...\n\nThanks,\nEugene\n"},{"id":"130086","messageId":"76c5b8580912181051j7e2ceb34p98127b316a0118ee@mail.gmail.com","threadId":"21985","inReplyTo":"76c5b8580912181030k56cb7dd7l811c0a0d4773d309@mail.gmail.com","subject":"Re: repo corruption - Egit's fault?","fromName":"Eugene Sajine","fromEmail":"euguess@gmail.com","sentAt":"2009-12-18T18:51:11Z","receivedAt":"2009-12-18T18:51:11Z","isPatch":false,"sender":{"key":"euguess@gmail.com","avatar":null},"body":"> Thank you for prompt answer, Shawn!\n>\n> The problem is that as i'm maintaining multiple repos and their\n> quantity will grow i would need to apply this setting site wide. Do\n> you know if i can specify this service for git daemon? It seems like\n> in git deamon docs this service is not listed, but just in case the\n> docs are not up to date... I really don't want to set this up for\n> every repo manually...\n>\n> Thanks,\n> Eugene\n>\n\nI found it.\n$ git config --global receive.fsckObjects true\n\nshould do the trick.\n\nThanks,\nEugene\n"}]}