My Company (Web Development) has decided to use Git. All repositories: employee (local repo) and remote repositories (bare repo) are stored on the central development server (OS X 10.9.1, Mac mini middle 2011). Developer connect to the development server from their iMacs over local network (OS X 10.7.5, 10.8.1 and so on, only Macs) and write the source code there. A Git client on Mac called Sourcetree should do the whole work. But after a few commits or some other git operations I get sooner or later following message:
fatal: unable to write new index file
After the message GIT can track the changes in the project, but I can't save anything to git. Even by using terminal or anotrher GIT-GUIs (I have tried Coda, GitHub) I get the same error message.
If the git client and the repository are stored on the same mac, everything works fine (tried on the development server and two iMacs). The problem occurs only if the git client has to connect to the repository over local network (AFP).
If I start the Git client on the development server and save some changes to the „damaged“ repository, everything works again. Also over local network. But if i work then in the repository on the development server with my local git client from my iMac over local network, I get sooner or later (mostly after a few adds or commits) the same error message.
I connect or login on server allways as the same user. Also Git client connects as the same user.
I suspect, that the reason is AFP.
I have enouth free space on the central development server. And have enouth file permissions, at least initially. These topics were not helpful for me:
What could I do?
The easiest, most robust solution will be to let your developers have the local repositories on their machines. The entire point of creating a DVCS like Git is so that the user can interact with their repository regardless of network connectivity.
If you want to require the network connectivity (maybe you are concerned developers will give away your proprietary code if they take their macbooks home, I can't think of any other reason to require this), then a DVCS isn't the right choice for you. Use SVN instead.
If you want to make sure developers' code is backed up, either task them with committing/pushing often, or download/purchase some backup software.
@Seth FossThank you for your prompt answer. Is it realy so, that GIT has problems with AFP/ shared folder? If it is so, I'll make the lokal solution you recommended. It was my second plan.
The reason for hosting "local" repositories on network storage was, that the web development testing server is allready configured for development and test of source code and backup. Also each developer could give a Link to other emploees in order to test the system.
If you can handle your GIT-Repository only localy, you should to configure/activate development environment, backup and share every Mac for other.
If it doesnt work with the network storage, I'll backup every mac and server and separatelly copy and backup local GIT-Repositoris.
Badges are a great way to show off community activity, whether you’re a newbie or a Champion.Learn more
Supported Platforms macOS Windows To make using Sourcetree as simple yet powerful as possible we embed (bundle) dependencies such as Git, Git LFS, and Mercurial. We strive to keep these...
Connect with like-minded Atlassian users at free events near you!Find a group
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no AUG chapters near you at the moment.Start an AUG
You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs