Ssh – Slow SSH Connection

networkingssh

I'm connecting to a Debian 5 server using PuTTY on Windows 7 from home. I have ADSL internet connection and a D-Link ADSL modem.

I've got a strange problem since 2 days ago. SSH connections became extremely slow, sometimes PuTTY fails to connect and sometimes it just hangs then times out in the middle of a session. My internet connection seems to be fine since my bandwidth is stable, i have no packet loss to anywhere including the server I'm talking about and there is no latency. Everything works just fine except for SSH.

I thought it might be something wrong with PuTTY so i tried 2 other SSH clients but i got the same strange slowness effect. I don't have access to any other server to see if SSH has the same problem or not. My friend connects to the mentioned server from somewhere else but he doesn't have this problem so i assume the server is not the cause.

I haven't tried to use another computer inside my home's NAT to see if it has the same problem or not. It makes no sense to me since everything was fine before 2 days ago. Could it be caused by the ISP?

Does anyone have an idea about how to fix the problem or how to find the cause?

Thanks

Best Answer

Which ISP are you using? That info might be useful as other people on the same ISP may be able to confirm the behaviour (as they have the same problem) or report all is well for them (indicating that the ISP doesn't have a general problem with SSH traffic).

One possibility if it is the ISP, is that they've changed their traffic management structure and it is mistaking your encrypted SSH connection as an encrypted P2P connection. If you can turn off the web server at the other end temporarily without causing to much trouble, try running SSH on port 80 to see if it runs better that way (if it does then something somewhere is probably doing port based traffic shaping that is affecting SSH). You could also try a bulk transfer via SSH (i.e. a download via SCP/SFTP) running through a HTTP based tunnel like this one to see what difference it makes (it will need to be a bulk transfer, as otherwise any performance issues will be hidden by the extra latency added by the tunnel).