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

Please Execute Git GC on this repository

coderakesh September 17, 2023

Hello Atlassian Team,

I have following repository on my workspace , I have take required steps to reduce the Size of My repo But the Changes are not reflected yet on Bitbucket.

It would be great if you run git gc on my repo from your side. And Please Mention the Updated Size. Also I want to ask How can I run or trigger garbage collection from our side if in your we run into this issue again.

workspace -  [REDACTED]

repository - [REDACTED]

1 answer

1 accepted

0 votes
Answer accepted
Ben
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
September 18, 2023

Hi again,

I've executed a gc against that repository and the gc has reduced the size of the repository from 3.1GB to 1.9GB.

Hope this helps.

Cheers!

- Ben (Bitbucket Cloud Support)

coderakesh September 18, 2023

.

coderakesh September 18, 2023

"Please check again when I'm done cleaning the repository. It was around 1.2GB, which is significantly smaller than I have on remote."

Please Sync the changes.

coderakesh September 18, 2023

Hello @Ben Can you Please check this

Syahrul
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
September 18, 2023

Hey @coderakesh 

Have you pushed the change from your local copy to remote? I have triggered the GC, and the repo size remains at 1.9 GB, which means the repo is still not updated with the changes you made locally.

Regards,
Syahrul

coderakesh September 18, 2023

Hey @Syahrul

Apologies for your Inconvenience But Can you Please Again Check if the newly changes i made affected the size or not, It would be great help.

And Please Also Let me know about the Size if it changes.

Regards

coderakesh September 19, 2023
Ben
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
September 20, 2023

Hi @coderakesh 

The repo size has remained the same, I would suggest executing the following command to locate large files in your repository:

git rev-list --objects --all \
| git cat-file --batch-check='%(objecttype) %(objectname) %(objectsize) %(rest)' \
| awk '/^blob/ {print substr($0,6)}' \
| sort -r --numeric-sort --key=2 \
| numfmt --field=2 --to=iec-i --suffix=B --padding=7 --round=nearest

Once you have located these large files, you can then follow our documentation below to either convert these to LFS or remove them from your GIT history (keeping in mind that each commit will store this large file repeatedly, therefore inflating your size significantly):

https://support.atlassian.com/bitbucket-cloud/docs/use-bfg-to-migrate-a-repo-to-git-lfs/ 

Cheers!

- Ben (Bitbucket Cloud Support)

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
TAGS
AUG Leaders

Atlassian Community Events