• Icon: Suggestion Suggestion
    • Resolution: Answered
    • None
    • None
    • None
    • We collect Bitbucket feedback from various sources, and we evaluate what we've collected when planning our product roadmap. To understand how this piece of feedback will be reviewed, see our Implementation of New Features Policy.

      Related to https://answers.atlassian.com/questions/12270327 .
      It would be great to have an option to schedule regular, pre-emptive Git GC's. (e.g. run GC every day at 2:00AM or every week on Sunday at 5:00AM)

      Git GC is quite resource-intensive on big repos and the response time towards users degrades while it is running.
      I would like Stash to run pre-emptive GC's at times of low load, to avoid them being triggered automatically by Git after a push in the middle of the workday.

            [BSERV-7102] Create option for scheduling regular Git GC's

            Katherine Yabut made changes -
            Workflow Original: JAC Suggestion Workflow [ 3396194 ] New: JAC Suggestion Workflow 3 [ 3618062 ]
            Status Original: RESOLVED [ 5 ] New: Closed [ 6 ]
            Monique Khairuliana (Inactive) made changes -
            Workflow Original: BSERV Suggestions Workflow [ 2687488 ] New: JAC Suggestion Workflow [ 3396194 ]
            Owen made changes -
            Workflow Original: Stash Workflow [ 832376 ] New: BSERV Suggestions Workflow [ 2687488 ]
            Status Original: Closed [ 6 ] New: Resolved [ 5 ]

            Thanks it34. We did some work previously in 5.2, it sounds like you've already got that.

            Roger Barnes (Inactive) added a comment - Thanks it34 . We did some work previously in 5.2, it sounds like you've already got that.

            We are on 5.5.0 right now, upgrading shortly (had to move some stuff around re disk space which is why we aren't on latest.

            Mutual Mobile IT added a comment - We are on 5.5.0 right now, upgrading shortly (had to move some stuff around re disk space which is why we aren't on latest.

            it34, could you confirm what version of Bitbucket Server you're running?

            Roger Barnes (Inactive) added a comment - it34 , could you confirm what version of Bitbucket Server you're running?

            it34, if you're asking whether it's ok to run git gc, it's not recommended. git gc does some good things (as we know), but it also does some things that Bitbucket's hosting needs prefer not to happen (and I must admit I don't have the exact details to hand, so I could be understating this). Instead, Bitbucket takes care of GC operations itself, calling lower level git functions to ensure the good changes happen, but not the less good ones.

            All that said, it's fair to say this arrangement could be made better, and we are looking at making some improvements.

            Roger Barnes (Inactive) added a comment - it34 , if you're asking whether it's ok to run git gc, it's not recommended. git gc does some good things (as we know), but it also does some things that Bitbucket's hosting needs prefer not to happen (and I must admit I don't have the exact details to hand, so I could be understating this). Instead, Bitbucket takes care of GC operations itself, calling lower level git functions to ensure the good changes happen, but not the less good ones. All that said, it's fair to say this arrangement could be made better, and we are looking at making some improvements.

            Mutual Mobile IT added a comment - - edited

            @roger.barnes Do you think it would be run `git gc` on every on repo? 

            find . -maxdepth 1 -type d \( ! -name . \) -exec bash -c "cd '{}' && git gc" \;

            in the /shared/data/repositories directory? I ran it on a few repos and saved a decent amount of space already. 

            Mutual Mobile IT added a comment - - edited @roger.barnes Do you think it would be run `git gc` on every on repo?  find . -maxdepth 1 -type d \( ! -name . \) -exec bash -c "cd '{}' && git gc" \; in the /shared/data/repositories directory? I ran it on a few repos and saved a decent amount of space already. 
            Bryan Turner (Inactive) made changes -
            Remote Link New: This issue links to "Page (Extranet)" [ 163968 ]

            Our use case is that rarely updated but highly fragmented git repos will not be garbage collected. This increases the footprint (size) of the repository, and greatly increases the time and space necessary for backups, especially with relatively high latency NAS filestores.

            Deleted Account (Inactive) added a comment - Our use case is that rarely updated but highly fragmented git repos will not be garbage collected. This increases the footprint (size) of the repository, and greatly increases the time and space necessary for backups, especially with relatively high latency NAS filestores.

              Unassigned Unassigned
              a8fb56ff7916 Balázs Szakmáry
              Votes:
              2 Vote for this issue
              Watchers:
              14 Start watching this issue

                Created:
                Updated:
                Resolved: