Problem: I have a seedbox and for FTP and SFTP connections get limited (probably my ISP?).
They’ll start strong, but quickly get throttled down to 300 kbps. I know my home connection goes “up to” 2 mbps.
Solution A:
Download a couple files at a time, with either Transmit or via a couple SCP processes in Screen. Not ideal as now you’re waiting just a long for a single file, but you’re multitasking.
Solution B:
-
split -b 500MB filename.mkv
-
scp
them in Screen -
cat xa* > filename.mkv
-
rm xa*
locally and on the server.
Faster for a single file, but wholly tedious. Lots of parts to remember. Depending on your file (4GB+ HD files), splitting and catting can take a couple minutes on both ends.
Solution C: LFTP
-
lftp
on Mini -
open [server name]
-
[queue] pget filename.mkv
Automates the worst parts of Solution B. Uses segmented downloading, and out of the box it downloads the file in 5 parts, saturating my connection. Locally there’s no cruft to join or delete. Super fast.
Key LFTP Commands:
-
open -u [username],[placeholder password] sftp://[server address]
- connect to your remote server -
pget [filename]
– segmented download of a single file -
mirror [foldername]
– download a directory -
queue [command]
– add said command to the task queue. The queue starts immediately. -
queue
– see current status of queued tasks -
bookmark add [name]
- save your remote server login information -
open [name]
- connect to a bookmark
LFTPRC
Create a .lftprc in your home directory and add these to ensure speedy downloads:
# use 10 connections by default (instead of the standard 5)
set pget:default-n 10
# use segmented downloading for directories
set mirror:use-pget-n 10
set mirror:parallel-transfer-count 2
set mirror:parallel-directories true