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

Remote: error: cannot lock ref 'refs/heads/master' when trying to push commits


I'm getting an error when trying to push local commits (either from VS or SourceTree) to 

on private repo

Remote: Error: cannot lock ref 'refs/heads/master': Unable to create '/opt/micros/data/cvs/vp1435/data/d-549/r-59335549/./refs/heads/master.lock': File exists.
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.

2 answers

0 votes
Caroline R Atlassian Team Dec 24, 2021

Hi, @Daryn Clarke

Thank you for reaching out to Atlassian Community!

As we will need to access the repository to remove this lock file, I went ahead and created an internal ticket for you using the email of your community account, so you don't have to share this information here. 

You should have received an email with a link to the support ticket. Just in case you haven't received it, please feel free to let me know and I can post the ticket URL here. The ticket will be visible only to you and Atlassian staff, no one else can view its contents even if they have the URL.

Please let me know if you have any questions.

Kind regards,

That's great Caroline, thanks for the quick response.

Like Caroline R likes this

@Caroline R I've seen you've been able to resolve this kind of issue before. Is it possible to delete the lock file in question manually as I'm unable to. Thanks.

Suggest an answer

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

📣 Calling Bitbucket Data Center customers to participate in research

Hi everyone, Are you Bitbucket DC customer? If so, we'd love to talk to you! Our team wants to dive deep to understand your long-term plans regarding Bitbucket DC and Atlassian Cloud. Do you plan...

123 views 2 4
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