Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

scp works well in all cases, but the Raspberry Pi is to weak to copy files efficiently in a secure environment (lan). The theoretically possible 6,75 MB/s via 54 Mbit wireless lan shrink down to about 1.1 MB/s.

Is there a way to copy files remotely without encryption?

It should be a cli command with no dependencies to extra services (ftp, samba) or at least with a minimum of configuration. I mean, a standard tool that works quite well out-of-the-box with standard programms/services (like scp/ssh).

share|improve this question
2  
"without any dependencies" is virtually not possible. you will always need a program that "listens" on one side (like the ssh/sftp server when using scp) –  umläute Feb 3 at 12:00
2  
What about netcat? –  yegorich Feb 3 at 12:01
    
Okay you're right. I will change the requirements –  ManuelSchneid3r Feb 3 at 12:01

5 Answers 5

up vote 6 down vote accepted

You might be looking for rcp, it performs remote execution via rsh so you will have to rely on that and have in mind that all communication is unsecure.

share|improve this answer

You cannot disable encryption completely on ssh/scp but you can force it to use a weaker cipher that is much less cpu intensive. Make sure that compression is not turned on in your ssh_config or on the command line and add -c arcfour,blowfish-cbc to your scp command line to select weaker ciphers.

share|improve this answer
1  
This is a nice idea. Is this possible for host specific config? (.ssh/config) –  ManuelSchneid3r Feb 3 at 17:27
2  
@ManuelSchneid3r: Yes: under a Host section in your ssh_config, use Ciphers arcfour,blowfish-cbc to mirror the above -c switch. However, if your CPUs support the AES-NI instruction set, I'd try switching to aes128-gcm@openssh.com (yes, that's the cipher name, including the @ stuff), which will use the blazingly fast (with AES-NI) AES128-GCM. –  Reid Feb 3 at 17:51
    
I wouldn't really call blowfish a weak cipher an in general case (i.e. not R-Pi) AEs might be boosted by hw acceleration. –  peterph Oct 21 at 21:22

I think NFS is quite underrated for this sort of task, where you want convenience, speed and don't care about security. NFS is really simple to set up, especially on the client: see this guide for ubuntu. From the client's perspective you just mount the server directory and it looks just like a local drive and you can use cp or rsync or whatever commands you want.

share|improve this answer

I wrote this quick script:

#!/bin/bash

ssh "$1" "nc -l 2020 > \"$2\" &"
pv "$2" | nc "$1" 2020

It takes two args, the host to send it to and the file you are sending. It only works for one file. It uses ssh to start a netcat listening on the opposite end and then uses netcat to send it to that listening port. I added pv to the start to give a nice progress bar. Replace pv with cat if you don't have or want that. Change the 2020 port to whatever you like. This requires you to have ssh access to the remote system.

This is completely insecure, but then, that's what you wanted.

share|improve this answer

There are patches for openssh for HPC (High Performance Computing) that improve ssh throughput by increasing transfer window sizes and disabling encryption - if you don't mind recompiling (and probably forward-porting patches), check HPN-SSH. As BowlOfRed noticed in the comment, you'd need to use the patches on both the client and the server.

You can also use rsync - on one machine as a daemon and as a simple client on the other one. It is particularly useful for synchronising larger volumes over network link that is slower than reading (and checksumming) the files, since it is able to transfer just those parts of files that differ between client and server. See rsync(1) and rsyncd.conf(5) man pages for details.

share|improve this answer
    
This was not explicit in your answer, but these patches include the ability to use the "none" cipher in SSH (in other words, disable encryption entirely). The drawback is that you have to apply and run it on both ends. A normal server won't accept the "none" cipher. –  BowlOfRed Oct 21 at 23:06
    
Very good point! –  peterph Oct 22 at 8:48

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.