Questions tagged [scp]

Secure Copy or SCP is a means of securely transferring computer files between a local host and a remote host or between two remote hosts. It is based on the Secure Shell (SSH) protocol.

The SCP protocol is a network protocol, based on the BSD RCP protocol, which supports file transfers between hosts on a network. SCP uses Secure Shell (SSH) for data transfer and utilizes the same mechanisms for authentication, thereby ensuring the authenticity and confidentiality of the data in transit. A client can send (upload) files to a server, optionally including their basic attributes (permissions, timestamps). Clients can also request files or directories from a server (download). SCP runs over TCP port 22 by default. Like RCP, there is no RFC that defines the specifics of the protocol.

Source: wikipedia

As per documentation of the most widespread implementation OpenSSH, the protocol is considered "outdated, inflexible and not readily fixed". Using more modern protocols like sftp and rsync for file transfer is recommended.

432 questions
28
votes
7 answers

Is there a GUI alternative to Putty SSH for transferring files?

Or any GUI SSH for Amazon ec2 Linux instance servers? I need to transfer files between two Linux virtual servers and currently I have PuTTY (which Amazon recommends). However I am new to the server/virtual world and have no experience with commands.…
javasocute
  • 443
  • 1
  • 4
  • 6
27
votes
12 answers

SCP copy windows local file to linux remote folder

How to get a file from my path d:/test.txt and copy it to /etc/var/test/test.txt? I've tried this: scp d:/test.txt /etc/var/test/test.txt but that didn't work. How do I set the hard disk from where I copy my files?
user3414354
  • 371
  • 1
  • 3
  • 3
27
votes
3 answers

scp files and delete files on remote directory

I am a unix noob, so please be patient :-) I have a script that scps a bunch of files to another server. Suppose they are z1.foo, z2.foo etc. What I want to do is to scp files and delete files older than 5 days in the destination server. How do I…
Kapsh
  • 519
  • 2
  • 6
  • 7
24
votes
5 answers

Difference between scp and sftp

What is the difference between sftp and scp?
Daniel
  • 3,791
  • 7
  • 33
  • 34
24
votes
10 answers

Copy large file from one Linux server to another

I'm attempting to copy a 75 gigabyte tgz (mysql lvm snapshot) from a Linux server in our LA data center to another Linux server in our NY data center over a 10MB link. I am getting about 20-30Kb/s with rsync or scp which fluctates between 200-300…
Nathan Milford
  • 792
  • 2
  • 10
  • 21
20
votes
6 answers

OpenSSH anything like 'internal-sftp' but for SCP?

I'm running Debian stable and I'm looking to establish the following environment for users in my 'sftponly' group: jailed can transfer with SFTP can transfer with SCP cannot login interactively with SSH From my experimentation and research, it…
brianjcohen
  • 301
  • 1
  • 2
  • 3
19
votes
2 answers

Why is scp not overwriting my destination file?

I'm trying to back up a file via the command scp /tmp/backup.tar.gz hostname:/home/user/backup.tar.gz When I run it, the scp progress bar shows up and it looks like its transferring the file, however when I log into the destination server to check…
Noli
  • 341
  • 1
  • 3
  • 8
18
votes
2 answers

What a pros and cons of FTP vs SSH for file transfers?

Why to consider setting up an FTP service on a server when files transfers work fine by means of SSH (with Midnight Commander on a Lunux and FileZilla on a Windows client)? What are pros and cons of both? Except of the fact tat FTP is more widely…
Ivan
  • 3,398
  • 19
  • 50
  • 71
16
votes
6 answers

Problems with SCP stalling during file copy over VPN

I have a series of files I need to copy via SCP over a VPN to a remote linux server each night. The files are not large, we're talking about tens of megabytes here, but the file copy almost always stalls after a few seconds. Running the SCP command…
MattC
  • 377
  • 1
  • 4
  • 11
15
votes
2 answers

Why is scp with compression slower than without?

I needed to transfer a 20 GB KVM vdisk file, storing the root filesystem of a CentOS 6.5 VM, from one lab server to another. The large file size and the fact that I had once compressed such a vdisk file to a few hundred mega-bytes made me…
pdp
  • 778
  • 1
  • 7
  • 16
14
votes
2 answers

Up-to-date alternatives of rssh or scponly

I need: An scp and sftp server With chroot-ed environment With non-login (ssh not allowed for scp/sftp users) Options and related issues I found: scponly No updates since more than 6 years Does one really need to recompile the whole thing to make…
Julen Larrucea
  • 338
  • 1
  • 3
  • 11
14
votes
5 answers

Running multiple scp threads simultaneously

Running multiple scp threads simultaneously: Background: I'm often finding myself mirroring a set of server files a lot, and included in these server files are thousands of little 1kb-3kb files. All the servers are connected to 1Gbps ports,…
caesay
  • 315
  • 2
  • 3
  • 9
14
votes
4 answers

SCP filename tab completion

I use SCP regularly to move files between servers and I've heard rumoured that you can use tab-completion on the remote server if you're using public keys, but so far I have had no luck. What I'm trying to accomplish is the following: scp -r…
user7195
14
votes
3 answers

Redirect output of mysqldump to scp

I worked with a Linux pro years ago who did this nifty trick. He could do a mysqldump but redirect the output to an scp/ssh connection rather than writing to disk. We used this quite a bit where I used to work but I cannot remember how to do this…
xzyfer
  • 323
  • 1
  • 5
  • 12
14
votes
2 answers

What does limit performance of scp?

I've two Debian Linux machine connected via 1 Gbit LAN. I can measure this with a raw HTTP file transfer with wget which gets around 100MB/s in either direction. When I now use scp, the maximum without compression I get is around 15MB/s. Enabling…
mark
  • 1,516
  • 5
  • 21
  • 33
1
2
3
28 29