# scp to remote servers stalls, unable to isolate cause

When I copy a large file (100+mb) to a remote server using scp it slows down from 2.7 mb/s to 100 kb/s and downward and then stalls.

The problem is that I can't seem to isolate the problem. I've tried 2 different remote servers, using 2 local machines (1 osx, 1 windows/cygwin), using 2 different networks/isps and 2 different scp clients. All combinations give the problem except when I copy between the two remote servers (scp). Using wireshark I could not detect any traffic volume that would congest the network (although about 7 packets/sec with NBNS requests from the osx machine).

What in the world could be going on? Given the combinations I've used there doesn't seem to be any overlap in the thing that could be causing the trouble.

-
Does this happen with other file transfers, http or ftp ? Have you asked your hosting provider if they are limiting your transfers. I have seen a similar effect with a firewall interrupting communication causing transfers to fail. Try using rsync with ssh if possible, does it help? –  daxroc Oct 16 '12 at 20:44
I have the same problem and the symptoms are exactly the ones described here: raim.codingfarm.de/blog/2012/05/31/… --- but I suppose that OpenSSH should not have that problem. –  Rmano Nov 18 '14 at 12:35

This could be caused by the MTU being incorrectly set.

Update

This is a possible duplicate of reliable-file-transfer-over-slow-or-flaky-network-link

You can get debug output from scp by adding -v argument - scp man page

My suggestion would be to use rsync over ssh

rsync -avz --progress --partial /path/to/copy ssh user@host:~/upload