Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Git GC not executed by Bitbucket

bodre
June 20, 2026

Repository size not reducing after history rewrite (force-push + filter-repo). 

Steps performed:
1. git-filter-repo --strip-blobs-bigger-than 5M --force
2. Force-push of all local branches (main + 10 feature branches) — no refs left pointing at the old history on my side.
3. git reflog expire --expire=now --all && git gc --aggressive --prune=now locally.

Verification on my end:
- Local .git: 526 MB → ~77 MB
- Fresh clone from Bitbucket transfers ~77 MB (so the new pack is being served correctly)
- HEAD tree SHA is identical pre/post-rewrite — no working-tree changes
Issue: the Repository size shown in the Bitbucket UI is stuck at 710.5 MB more than 24 hours after the rewrite. Per the documentation, background GC should reclaim orphaned packs within ~24h, but no change has occurred.

1 answer

1 vote
Arkadiusz Wroblewski
Community Champion
June 20, 2026

Hi @bodre 

The cleanup looks good, as a fresh clone is only 77 MB. The large UI size is likely due to Bitbucket holding onto internal refs, old PRs, or a stale cache.
Double-check for old tags/branches/PRs holding heavy objects. If clear, it's a server-side issue, Atlassian Support will need to run garbage collection.

I flagged this post for their attention.

Best,

Arkadiusz 🤠 

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
FREE
PERMISSIONS LEVEL
Product Admin Site Admin
TAGS
AUG Leaders

Atlassian Community Events