Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Deleted user
0 / 0 points
badges earned

Your Points Tracker
  • Global
  • Feed

Badge for your thoughts?

You're enrolled in our new beta rewards program. Join our group to get the inside scoop and share your feedback.

Join group
Give the gift of kudos
You have 0 kudos available to give
Who do you want to recognize?
Why do you want to recognize them?
Great job appreciating your peers!
Check back soon to give more kudos.

Past Kudos Given
No kudos given
You haven't given any kudos yet. Share the love above and you'll see it here.

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

I can't push after garbage collecting dead data (2gb < size of repository < 5gb) Edited


    With my last commit, I accidentally exceeded the 2GB limit

    after which I did the following:

  1. git reset --hard HEAD~
  2. tried "git push --force", but size of local repo didn't change, so it was pointless
  3. git reflog expire --expire=now --all
  4. git gc --prune=now

    On this stage size of local repo +- 200MB, but "git push --all --force" not works

fatal: TaskCanceledException encountered.
A task was canceled.
Password for '...':
Enumerating objects: 9, done.
Counting objects: 100% (9/9), done.
Delta compression using up to 16 threads
Compressing objects: 100% (5/5), done.
Writing objects: 100% (5/5), 444 bytes | 222.00 KiB/s, done.
Total 5 (delta 4), reused 0 (delta 0)
remote: Repository is over the size limit (2 GB) and will not accept further additions.
remote: Learn how to reduce your repository size:
To <repo link>
! [remote rejected] master -> master (pre-receive hook declined)
error: failed to push some refs to '<repo link>'


    Just in case: I'm not the admin of repo


   Sorry if this problem already was, but I can't search it 


Thank you in advance!

2 answers

1 accepted

0 votes
Answer accepted

Hello @Greysnek,

Welcome to the Community.

You did it right, here's the guide on how to reduce repository size. The repository size in Bitbucket doesn't necessarily reflect such cleanups immediately because garbage collection isn't triggered on every update being quite an expensive operation.

I kicked off GC for your repository, its size reduced to around 300Mb.

Let me know if you have any questions.


Big thank you

Like Daniil Penkin likes this

Suggest an answer

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

Calling any interview participants for Bitbucket Data Center

Hi everyone,  We are looking to learn more about development teams’ workflows and pain points, especially around DevOps, integrations, administration, scale, security, and the related challeng...

504 views 6 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