You can limit the bandwidth the
scp uses with the
-l switch, you pass a number that's in kbits/sec.
I'd rather set this in my
.ssh/config file for certain names machines.
What's the equivalent named setting for
-l? I haven't been able to find it.
Generally, not sure how to map back and forth between ssh command line options and config names, short of doing Google searches or manually comparing man pages on a case by case basis. Is there a table that directly equates the two?
Longer form of first question, with context:
I've started using ssh config quite a bit, especially now that I need to go through a proxy and do lots of port mappings. I even define the same machine more than once depending on what type of tunneling I need.
However, when uploading a large file, it's difficult to do anything else on my machine. Even though I have more download bandwidth than up, I think that
scp saturates the link so even my small requests can't reach the Internet.
There's a fix for this, using the
-l bandwidth command line switch for
scp -l 1000 bigfile.zip titan:
I'd like to use this in my config instead, so I'd create an additional named entry called "titan-upload" and I'd use that as the target whenever I upload.
So instead of:
scp bigfile.zip titan:
scp bigfile.zip titan-upload:
Or even set different caps depending on where I am:
scp bigfile.zip titan-upload-from-work: vs. scp bigfile.zip titan-upload-from-home:
I'm generally on Mac and Linux.