On Friday, February 22, 2013 9:35:18 AM UTC+1, Ralf Kaiser wrote:
> we are using GIT (V1.8.1) in our build process inside a MSBuild script on
> When clone our main repositories to the build machine we sometimes get the
> message "Unable to rename <repository>/.git/.HEAD.lock to
> <repository>/.git/.HEAD - Retry (y/n)".
> At that time the build process hangs because there is nobody that can
> answer that question :-(
> The cloning of the repositories works in 9 of 10 cases without that
> Any hints what causes that message? (it is an absolute no-go inside a
> script - an error code would be OK but asking the user is absolutely not
> Thanks in advance,
Sounds like the file has been locked by something. Needless to say, if some
process starts locking files inside the .git repository, Git can't work.
See if you can inspect on the build server when this happens, and use some
tool to figure out which process has locked the file:
Once you know which process, you have to figure out how to stop it from
Perhaps the good folks at the msysgit mailing list can assist further. I've
cc'ed them in this email.
You received this message because you are subscribed to the Google Groups "Git
for human beings" group.
To unsubscribe from this group and stop receiving emails from it, send an email
For more options, visit https://groups.google.com/groups/opt_out.