Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Commit, pull and push fail because of unresolvable problem with index.lock

Recently I have this problem all the time when I try to commit, push or pull.



git -c diff.mnemonicprefix=false -c core.quotepath=false -c credential.helper=sourcetree fetch origin

git -c diff.mnemonicprefix=false -c core.quotepath=false -c credential.helper=sourcetree pull origin master


* branch            master     -> FETCH_HEAD

error: Unable to create '/Users/jlw/Documents/phds/ferdi/phd_thesis/.git/index.lock': File exists. 

Another git process seems to be running in this repository, e.g.

an editor opened by 'git commit'. Please make sure all processes

are terminated then try again. If it still fails, a git process

may have crashed in this repository earlier:

remove the file manually to continue.

Updating 9af7830..8772a55

Completed with errors, see above

This happens across multiple repos, and operations. Any suggestions?

1 answer

By the way, I've tried killing stray git processes, restarting, and deleting the index.lock file. These don't seem to work (at least not reliably)

Did you find an answer to this problem?

Suggest an answer

Log in or Sign up to answer
Community showcase
Published in Sourcetree

Tip from the team: configure your repos for hosting goodness!

Supported Platforms macOS Windows We recently introduced support for additional hosting services such as GitHub Enterprise, GitLab (Cloud, Community Edition, Enterprise Edition), and...

5,692 views 4 12
Read article

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you