I am starting to开发者_如何学编程 use Git. I feel it is important to point out that this was not my choice. I have found Git to be problematic to understand but largely stable, until last month. A week into Dec 2010 I found that I could no longer push to our "central" repository. The process would reach 70% on writing objects and then hang. We have no Git "experts", but I asked some of the other people that have been using it and was given a number of suggested resolutions. Issues with Logitech webcams, attempting to do the push from Safe Mode 9 (with networking obviously), using the command line in Git bash rather than Tortoise. None worked. What I ended up doing was uninstalling msysgit and reinstalling it. That resolved the issue. Or so I thought. A couple of days ago the issue recurred. I can no longer "push" to our repository.
I suppose I could just plan on reinstalling msysgit every month from now on, but that seems like to great a concession to me. :-)
Any idea what I can do to resolve this, or even troubleshoot it?
There may be issues with where it is hosted. I've been using git (msysgit) since 2008 and never had such an issue. I would recommend hosting the server on a linux VM though. That's made things faster and gitolite is excellent for permissions.
Hope this helps.
Turns out it was the version of Git, not the OS that was the issue. I had installed Git version 1.7.?. The Server was running version 1.6.4. Byt downgrading my client to 1.6.4 I have not had any issues. Thanks for your assistence on this. I still think I will likely go back to ClearCase until there is more support for Git within my organization. As for adymitruk's comment "You just can't beat what Git enables you to do.", that may be true in general, but I have seen little advantage of Git over SVN for my work. Maybe I am just not enough of a Geek. Maybe I am just stupid as Linus say all SVN users are.
Thanks again Pat O
It seems like this is not a common problem, so I suggest you attempt a series of tests to see where the problem occurs:
- Set up a remote repository on another machine (such as your work companion's computer) and see if you can complete the transaction to that repository to see if it's a repository problem or network problem
- Try it on another network to see if there's a problem with proxy servers, NAT, etc in the way (shouldn't be an issue, but who knows what your work network is like)
- The repositories are simple directory/file structures. Try copying the remote repository onto a flash drive, and then put it in your local machine and try to update it locally. This eliminates the network and your update method (server, ssh, etc) from the chain of components to see if there's a problem with the repository itself (perhaps it's corrupted).
Rather than post an exhaustive list of troubleshooting possibilities which would be nearly endless, consider all the parts of the system you are interacting with and try to narrow down the problem by replacing parts of it (ie, the tool, your local repository, the remote repository, the network, etc, etc, etc) Also, make sure you are using the tools correctly - it shouldn't take a long time to transfer a few changes.
Just another datapoint -- this could be related to Issue 457 on the msysgit project site. There is a patch with a workaround (from Feb 2011), but as of today (June 13, 2011) they have not included it in a release.
精彩评论