Is there a gitlab setting for packSizeLimit ?

741 views
Skip to first unread message

Ryan W

unread,
Nov 14, 2014, 2:08:20 PM11/14/14
to gitl...@googlegroups.com
Right now our gitlab server is using up all of it's memory when people try to clone repos over 3GB in size.. I've created a 2GB swap partition but we're still chewing through all of that for larger repos as the packing process sucks up more ram than we can spare.  So I wanted to check if there is a setting that I can configure in Gitlab or if I should install git and set it that way? 

The server instance I setup gitlab on doesn't have git installed so I am going to have to apt-get install git to get it up and running in order to set my packsizelimit.  Not wanting to rock the boat I assumed that git wasn't installed for a reason and wanted to check if there was a gitlab only way that I could adjust this variable to limit the pack size to a few hundred MB instead.

thanks!

Ryan W

unread,
Nov 17, 2014, 1:23:47 PM11/17/14
to gitl...@googlegroups.com
So what I did was went in and updated the  /var/opt/gitlab/git-data/repositories/reponame.git/config file so it looked like this:

[core]
        repositoryformatversion = 0
        filemode = true
        bare = true
[pack]
        windowMemory = 128m
        packSizeLimit = 512m

and then repacked the repo: #git repack -a -d

I also increased the swap from 2 to 3GB but after these settings were in effect and the repo repacked, git hardly touched the swap file.

What I would love to know however is if a file I can edit that controls what those initial config files look like so I don't have to do this for every new repo that is created

rodrigo....@vizexplorer.com

unread,
Jul 25, 2017, 5:51:29 PM7/25/17
to GitLab
In case anyone comes across this as I did, you can set this globally by using
    git config --global [configuration option]

there probably is a file for it, but that's how you can do it at least from cmdline and it should apply to all new projects as well
Reply all
Reply to author
Forward
0 new messages