Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,298,169
Community Members
 
Community Events
165
Community Groups

Git push fails with error: Cannot lock ref 'HEAD': Unable to create xxxx/HEAD.lock: File Exists

Edited

Hi All, I am seeing below error when trying to push to master:

$ git push

Total 0 (delta 0), reused 0 (delta 0)

remote: error: cannot lock ref 'HEAD': Unable to create '/nfs/bitbucket/data/repositories/xxxx/./HEAD.lock': File exists.

remote: 

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

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

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

remote: may have crashed in this repository earlier:

remote: remove the file manually to continue.

 

I don't see any .git/HEAD.lock or .git/index.lock files in my repository

Any suggestions on what I can do to resolve this?

1 answer

0 votes
Caroline R Atlassian Team Jul 05, 2021

Hi, @Abhinav Bezgam! Welcome to the community! 

I saw you created a ticket with our support related to the same question, so to avoid any possible misunderstandings or miscommunication that may arise from discussing the same matter on two different platforms, let’s focus on the ticket instead.

Feel free to share the resolution here to help other community members that may have the same issue. 

Kind regards,
Caroline 

Hi,

 We're seeing this same issue. Under what support ticket is the discussion progressing?

Hi @jarkko_lietolahti and welcome to the community.

A support ticket is visible only to the user that created it and Atlassian staff, it's not publicly visible.

There hasn't been any progress in the support ticket as the reporter hasn't engaged in the discussion.

My suggestion would be that you create a separate question for your issue, providing details on the errors you see and also whether it concerns a Bitbucket Cloud or Bitbucket Server repo. We generally encourage users to create a new question for their issue instead of posting on someone else's question, because 1) the root cause and resolution may be different for each case 2) a question can become cluttered and difficult to follow if we try to troubleshoot multiple users' issues in it.

Please feel free to let me know if you have any questions.

Kind regards,
Theodora

Hello I have the same issue

Hi @N-Y Corp ,

I would like to ask if you could please create a new question for your issue, providing details on the errors you see and also whether it concerns a Bitbucket Cloud or Bitbucket Server repo.

We generally encourage users to create a new question for their issue instead of posting on someone else's question that they have the same issue, because 1) the root cause and resolution may be different for each case 2) a question can become cluttered and difficult to follow if we try to troubleshoot multiple users' issues in it.

Please feel free to let me know if you have any questions.

Kind regards,
Theodora

Suggest an answer

Log in or Sign up to answer
TAGS
Community showcase
Published in Bitbucket

Git push size limits are coming to Bitbucket Cloud starting April 4th, 2022

Beginning on April 4th, we will be implementing push limits. This means that your push cannot be completed if it is over 3.5 GB. If you do attempt to complete a push that is over 3.5 GB, it will fail...

2,224 views 2 9
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