Support #5618

Getting HTTP 502 Bad Gateway when trying to push (or clone) on a slow network

Added by Claude Chausse over 2 years ago. Updated over 2 years ago.

Target version:
Start date:
Due date:
% Done:


Estimated time:
Commit Number:
Affected Version:


When we try to push (sometimes it happen on clone) on a network that is slow (not sure if is it is related to bandwidth or latency), we have issues and the operation fails. Usually the error we get is HTTP 502 Bad Gateway. The problem is systematic on some network (ex: people in Argentina or California).

My Rhodecode server (which is running version 4.13.3) is sitting behind an Apache frontend which is used as the Proxy and is providing the Secure HTTPS channel

I included the apache configuration (related to the rhodecode virtualHost) and the rhodecode.ini

I tried to use some trick that I read on some forum like tweaking the timeouts of play with the keepalive settings but it did not help

basically I never could resolved this issue that we started having a few years ago and this is causing big frustration for people working from remote location where we have to setup an intermediate server for them to use and have to synchronize them.


apache2.conf (1.25 KB) apache2.conf Claude Chausse, 27.05.2020 19:04
rhodecode.ini (23.1 KB) rhodecode.ini Claude Chausse, 27.05.2020 19:05

Updated by Marcin Kuzminski [CTO] over 2 years ago

This could be related to Gunicorn timeouts/keeplive. Here are the new defaults and settings we use in latest releases:

Before we used to set those via (please check this, not sure how it was on 4.13 this release isn't supported anymore)
502 reported by Apache is most likely RhodeCode timeouts not Apache

Also available in: Atom PDF