Issues

Issue #10063 open

SSH Very Slow compared to HTTPS

Michael Daly
created an issue

SSH is consistently much slower than HTTPS

I just cloned a 17.5MB repo

6 minutes to clone via SSH 1 minute to close via HTTPS

I've noticed this consistently for as long as I have been using SSH, pulls and pushes are much slower than HTTPS.

Comments (8)

  1. Destan Sarpkaya

    I think this is related to neither git nor bitbucket but respective protocols. So there is nothing that Atlassian could do about it.

    By the way, I am not surprised that ssh packages are "heavier" than https ones.

  2. Kaleb Elwert staff
    > time git clone https://bitbucket.org/belak/dotfiles d1
    Cloning into 'd1'...
    remote: Counting objects: 568, done.
    remote: Compressing objects: 100% (509/509), done.
    remote: Total 568 (delta 206), reused 0 (delta 0)
    Receiving objects: 100% (568/568), 1.09 MiB | 180.00 KiB/s, done.
    Resolving deltas: 100% (206/206), done.
    Checking connectivity... done.
    git clone https://bitbucket.org/belak/dotfiles d1  0.09s user 0.09s system 1% cpu 10.362 total
    > time git clone git@bitbucket.org:belak/dotfiles d2
    Cloning into 'd2'...
    remote: Counting objects: 568, done.
    remote: Compressing objects: 100% (509/509), done.
    remote: Total 568 (delta 204), reused 0 (delta 0)
    Receiving objects: 100% (568/568), 1.09 MiB | 959.00 KiB/s, done.
    Resolving deltas: 100% (204/204), done.
    Checking connectivity... done.
    git clone git@bitbucket.org:belak/dotfiles d2  0.05s user 0.07s system 3% cpu 3.329 total
    

    For me, the ssh cloning is much faster, though, admittedly, it's a smaller repo.

    If you look at the documentation, HTTPS cloning should take more time, as it generally requires multiple round trips, while ssh can do it all in one connection. Sometimes https is used as a fallback because ISPs will either block or throttle SSH connections.

    I'm closing this as on hold for now, as I don't see it on our end. If you'd like to debug this further, support@bitbucket.org would probably be a better place for it.

  3. Mauricio Leyzaola

    I am having very low download rates using both SSH and HTTPS, around 21 KiB/s. It happens randomly, I think this is an issue related to Bitbucket itself, not the protocol used. Please reopen this ticket, this performance is not normal!

    Screenshot 2015-04-22 21.31.24.png

  4. Michael Daly reporter

    I've just moved a repo used by our build server to SSH because HTTP seems to get blocked when we are using it heavily. SSH is still ridiculously slow compared to HTTP. It doesn't appear to be related to connection speed, more to do with waiting for hg commands to start sending data.

    SSH seems to be the recommended protocol by BitBucket, yet it offers a much poorer experience. Kaleb (Staff) did one test on a 1MB repo, any substantial project is going to be in the 10's MB or 100's MB with lots of files.

    Should we just assume that closing the ticket = don't care & not going to research (or something else). I'd prefer that you just gave an answer rather than the burying head in sand approach.

  5. Mauricio Leyzaola

    Thanks Michael for reopening. I really think you Atlassian guys need to do something about this. As a test, I moved one of my repos to gitlab and works very fast. Probably SSH is slower than HTTP but with gitlab it is hardly noticeable. Moreover I would buy it if HTTP was downloading at normal speed, which isn't the case. Cheers.

  6. Log in to comment