Secure Copy or SCP is a means of securely transferring computer files between a local and a remote host or between two remote hosts.

learn more… | top users | synonyms

2
votes
2answers
80 views

SCP files from machineB to machineA

I am trying to scp the files from machineB to machineA. I need to run the scp command from machineA to copy files from machineB to machineA. The file that I need to copy from machineB is - ...
-1
votes
1answer
2k views

How to copy only new files using “scp” command?

I was copying hundreds of files to another computer using the scp command that I got the stalled error. Now I am going to copy the files again. Is there any way to avoid copying the already copied ...
-2
votes
2answers
528 views

How to copy only the files of a folder(including subfolder's files), but not the folder itself in shell

In Openssh, On the client, the content of path/to/file must be copied to Server. All files in /path/to/file on the client must be copied to /path/to/files on the server. Note: only copy files, no ...
1
vote
4answers
132 views

Exclude characters for SCP-filepattern

Is there a way to build an expression for scp with which I can manage to copy the file file-name-version-1.2.1.jar without copying the files file-name-version-1.2.1-sources.jar ...
2
votes
3answers
192 views

How to compress and transfer folders from one server to another over network

Do we have any option to transfer folder from one server to another, that is faster and compressible and bandwidth limit settable method? The servers run on Linux. I tried tar + ssh but I couldn't ...
2
votes
2answers
330 views

scp does not display output when used with gnu parallel

I have a short script that uses scp to copy files to a number of remote hosts (yes, I know about rdist and rsync; they both fail to work for a few of the hosts - that's not the point here; I'm only ...
4
votes
1answer
464 views

Weird SSH/SCP progress meter behavior

I've got a very weird SSH behavior and it's making me a bit nervous. Basically the progress meter is totally bogus: so bogus that it's nearly useless. And I fear that there may be something else going ...
2
votes
3answers
378 views

scp and umask setting

How do i make SCP respect umask ? Ive tried adding this Subsystem sftp internal-sftp -u 0002 in /etc/ssh/sshd_config and session optional pam_umask.so umask=0002 in ...
0
votes
2answers
59 views

I'm trying to install my public key manually w/ scp

I'm following a tutorial and it's going along well. I used ssh to connect fine. Then I created a private and public key. Which leads me to my first question it says that the keys have been saved to ...
0
votes
1answer
67 views

Loss of .eps file quality after using scp to transfer from remote server

When I scp (secure copy protocol) a .eps image file (generated using IDL) from a remote server to my desktop, the image seems to be of a lowered resolution and "choppy". Strangely, when I transfer ...
3
votes
1answer
405 views

Rsync over ssh tunnel - using gateway server

Environment: ---------- ---------- /| ------------ | Work | | Gateway| | | | cluster | |Station |--------------------------------| ...
0
votes
1answer
1k views

Why does scp say “No such file”?

I have a bash script that uses scp to copy a file from my machine to another. The script keeps on exiting after I enter the SSH password with the error: <filename>: No such file or directory ...
4
votes
2answers
257 views

SCP file between 2 servers that go through few servers

I want to copy a file from server-a to server-d but I can access server-d only from server-b and then to server-c. server-a can only access server-b, server-b can only access server-c, server-c can ...
5
votes
2answers
371 views

How to disable the try again password in ssh command

I want the ssh command to only allow one chance in typing the password, if the password was wrong at the first time the ssh will return Permission denied (publickey......). Is there a flag that ...
0
votes
2answers
225 views

scp from remote host fails due to login greeting set in .bashrc [duplicate]

My simple file scp from a remote host (actually a locally run VM but that shouldn't matter) failed without displaying any error message but clearly not having copied the desired file: scp ...
2
votes
3answers
4k views

Copying files from one machine to another without asking for password

I am currently using this command. I am on another machine (ip1) scp file.txt root@ip2:/home/praveen/test.c /home/praveen The command will prompt for password. I use it in some shell scripts, and ...
4
votes
5answers
4k views

How to securely allow scp, but not ssh

I work from a Mac Book Pro (called foo). I have a server where my customers scp large files to. (called bar). I frequently ssh into bar, and scp a file (called buzz) to my Mac. bob@foo$ ssh bar ...
1
vote
1answer
126 views

Remote PC accessible by ssh, scp/rsync not working (anymore) [closed]

I've got a remote machine running Ubuntu 12.04 LTS. I've used it lots of times to log in to via ssh and to copy files to via scp and rsync. Today I was able to log in via ssh, but I'm not able to ...
1
vote
2answers
665 views

Bash function to scp a file not working

I am new to bash scripting and read basic tutorials online and wrote following simple bash function: function to_company() { scp ${1} username@long.server.name.company.com://home/username } ...
1
vote
2answers
254 views

errors trying to transfer via SCP [closed]

I'm trying to transfer a file between two servers and i'm getting different errors. Option 1: Logged at OLDSERVER via SSH scp file.tar.gz root@IPADDRESS:/var/www/. The error in this case is ...
4
votes
3answers
3k views

scp from one remote server to another remote server

I have one big file on server one and I want to copy it to server two using scp. I have the keys setup properly and I can ssh/scp to both servers from my desktop. The file I need to copy is larger ...
0
votes
1answer
1k views

scp stuck when trying to copy files from Linux to windows

I use the following scp syntax in order to transfer a lot of files from Linux red-hat 5 to windows machine (under Temp directory). SSH server is already installed on windows machine. I use this line ...
1
vote
1answer
205 views

Run command after nice command has finished

I have 3 nice commands that are dumping some databases, and compress assets for a backup. After that, the files should be copied to another server. I'm using this command: nice mysqldump -u user1 ...
4
votes
2answers
94 views

ssh to a specific machine within a network [duplicate]

I'm frequently transferring files and operating programs via ssh, and often from home. The machine I usually work on is a desktop at work that I cannot ssh to directly unless I'm already connected to ...
0
votes
0answers
21 views

file modified while doing scp/cp [duplicate]

I'm doing scp to a database while it's active. Its not very critical but I would like to know what will happen to a file when it is modified in the middle of a cp process? Does it get corrupted or it ...
1
vote
1answer
194 views

how to get Cisco IOS public key for automatic scp connection

I want to backup the running-config of all switches per SCP to a server. Question 1: is this possible with kron? Is there a better way and why? Question 2: how can I get the public key of the switch ...
1
vote
4answers
182 views

using scp command to transfer files keeping the same names intact?

Using scp command I want to move files from local system to a remote system. I'm doing something like this: $ scp file1 root@abc:root /root/tmp With this command I'm able to upload file1 to ...
2
votes
1answer
169 views

scp refuses to do anything but print usage

I'm trying to copy a file on my home network using scp. However, every time I run it, it just prints usage instructions. $ scp alex@192.168.0.4:ipdetect-0.6.tar.bz2 usage: scp [-12346BCpqrv] [-c ...
3
votes
1answer
144 views

Copy symlinks from ext3 to cifs share

I'm using scp to copy files from a Linux disk (ext3 file format) to a Windows disk (NTFS exposed using CIFS over the network). I've found that scp follows symbolic links and copies their contents ...
1
vote
2answers
1k views

How can I scp a file that my user can't read but I can sudo?

Can I use scp to copy a file from a remote server which my login user can't read, but where I have permission to sudo to root (without password even)? How?
2
votes
2answers
462 views

scp to /home changes permissions?

This would be illustrated very nicely with an scheme. When I write "Test: OK" or "Test: FAIL" I am restarting apache server (httpd service). Basically, performing everything as root in the ...
2
votes
1answer
179 views

ssh/scp works but rsync just constantly says “no”

Hi I have a windows 2003 server that I need to back up onto a linux client so I install cygwin on the Win2k3. On the Win2k3 I have enabled ssh, scp but (because the Win2k3 server uses an customised ...
0
votes
1answer
110 views

Indirect SCP connection

I use ssh and scp to connect to a remote server. Due to a ip/proxy limitation on the remote server, I have to connect first to another server. For example, if I want to connect to "SERVER-A", I have ...
2
votes
2answers
3k views

How to scp/tar files that are in between specific days?

I need to copy db log files between two suse servers where I am interested in files ONLY in between 10.3.2013 - 13.3.2013 It is desired to compress the files before copying so I tar them and scp. ...
0
votes
2answers
428 views

scp hangs on SSH2_MSG_SERVICE_ACCEPT received

I frequently scp my file to remote host. But suddenly it started taking more than 30 seconds to copy 20kb file.It used to take not more than half a second. After referring to some blog I appended ...
1
vote
1answer
303 views

scp recursively directories on SunOS

I have encountered a small issue with SCP (and also rsync). I need to copy certain files from server A (running SunOS 5.8) to server B (running SunOS 5.10). First, I get the list of files (several ...
8
votes
1answer
6k views

scp and compress at the same time, no intermediate save

What is the canonical way to: scp a file to a remote location compress the file in transit (tar or not, single file or whole folder, 7za or something else even more efficient) do the above without ...
1
vote
1answer
615 views

Transferring Files SSH SCP Error Message: 'Stdin: is not a tty'

I am using a Macbook SSH terminal and generated RSA key pairs and uploaded remote id_rsa.pub with approved permissions. I can connect with remote Apache web server. I can create, open, move, modify ...
2
votes
3answers
2k views

How to scp with regular expressions

I'm trying to copy all files that do not begin with the letter "a", in ksh. Copying from the source machine to destination machine is working fine: scp -p !(a*) user@machine:/path/directory/. But, ...
1
vote
5answers
2k views

Changing user while scp

I need to copy file between Linux machines. The problem that the user I use to login (myuser), is different from the user that can access the file. If I just ssh to the machine, I can switch the user ...
11
votes
4answers
3k views

Does a `scp` transfer close when I close the shell?

I have scp transfer (from one remote server to another), that is quite big. So maybe I want close the computer from which I executed this command, will this end the transfer? I have ssh access to ...
1
vote
4answers
826 views

How to copy Big files on other Linux Server Independent of TTY

Actually i was trying to copy all the files in another director. Total size of the file is 188GB so its going to take a time. Im trying to copy for Linux server A to B using this command nohup scp ...
0
votes
1answer
207 views

scp current folder to destination folder name as ddmmyy

I want to add a cron job that scp a folder to a server with on the server the folder name is in another folder whose folder name is a timestamp like ddmmyy something like scp -r <foldername> ...
5
votes
3answers
531 views

Tar piped to split piped to scp

So I'm trying to transfer a bunch of files via SCP. Some of these are too large to be stored on the recipient (Android phone, 4GB file size limit). The sender is almost out of space, so I can't ...
1
vote
3answers
4k views

scp force overwrite read only files

I was wanting to use scp to move some files and overwrite any existing instances of these files on the destination server. Some of them may be read only which, of course, courses the scp to fail with ...
0
votes
1answer
130 views

I'm only allowing pubkey auth via ssh. How can I still log in with password?

vi /etc/ssh/sshd_config egrep -i 'Pubkey|Password|Listen' /etc/ssh/sshd_config | grep -v '^#' ListenAddress 0.0.0.0 PermitRootLogin without-password PubkeyAuthentication yes ...
2
votes
2answers
339 views

Transfer a file from Android to a PC (not in the same network)

If I were connected by wifi in my network, there isn't any problem because with AirDroid I can access the sdcard files using the browser. However when I am out, how can I transfer a file from my ...
2
votes
3answers
1k views

Suppress server message in rsync

When I rsync or scp from a particular server I get a rather long message telling me the rules of the server. However when I setup regular pulls, I'd like to be able to suppress those messages in my ...
5
votes
2answers
2k views

Scp doesn't work in cron

Yeah, I know it's classic. I've googled it all around, but still it doesn't work. I have the following script: #First go to SVN repo folder cd $svnrepos # Just make sure we have write access to ...
2
votes
2answers
443 views

I can ssh into a remote machine but I can't use scp to copy local stuff to the remote machine

I'm using a remote machine, which is in a lab and the administrator ask a RSA public key and then I can login into that machine using a passphrase I set now I want to use scp to copy local stuff to ...