Git clone fail. RPC failed; curl 18 transfer closed with outstanding read data remaining

Greetings :slight_smile:,

I get timeouts when I clone a large repo from our self hosted Gitlab-ce server running v9.5.3.

I have set the timeouts for 3 hours, but I get the below error after 1 hour. Are there any other settings I can set to fix this ?

Command:
git clone https://gitexample.com/group/test.git --depth 1 --no-single-branch

Error:

14:29:48.154169 pkt-line.c:80 packet: sideband< \2Compressing objects: 100% (10042/10042) \15
14:29:48.154179 pkt-line.c:80 packet: sideband< \2Compressing objects: 100% (10042/10042), done.
remote: Compressing objects: 100% (10042/10042), done.
14:29:48.154199 pkt-line.c:80 packet: sideband< PACK …
14:29:48.154267 run-command.c:626 trace: run_command: ‘–shallow-file’ ‘/private/tmp/wp-as391/.git/shallow.lock’ ‘index-pack’ ‘–stdin’ ‘-v’ ‘–fix-thin’ ‘–keep=fetch-pack 13500 on Infinite.local’ ‘–pack_header=2,16188’
14:29:48.165043 git.c:344 trace: built-in: git ‘index-pack’ ‘–stdin’ ‘-v’ ‘–fix-thin’ ‘–keep=fetch-pack 13500 on Infinite.local’ ‘–pack_header=2,16188’
Receiving objects: 95% (15520/16188), 687.86 MiB | 154.00 KiB/s

  • transfer closed with outstanding read data remaining00 KiB/s
  • stopped the pause stream!
  • Closing connection 0
    error: RPC failed; curl 18 transfer closed with outstanding read data remaining
    fatal: The remote end hung up unexpectedly
    fatal: early EOF
    fatal: index-pack failed

mac gitconfig:

[http]
postBuffer = 104857600000
sslVerify = false

Gitlab.rb config:

gitlab_rails[‘git_timeout’] = 10800
nginx[‘keepalive_timeout’] = 10800
unicorn[‘worker_timeout’] = 10800
nginx[‘redirect_http_to_https’] = true
nginx[‘custom_gitlab_server_config’] = “proxy_max_temp_file_size 0;”

Hi there,

Have you tried following the troubleshooting documentation on git clone over HTTP fails with transfer closed with outstanding read data remaining error? Suggestion there is to increase the postBuffer on the git config:

git config --global http.postBuffer 524288000