Tuesday, April 3, 2012

HowTo - ssh, sftp, scp

Download from remote server:
$ sftp username@server.com
$ get filename

Upload to remote server: *
$ sudo scp filename username@server.com

SCP a file to Duke CS my home directory
$ sudo scp filename username@server.com:~/
(Don't forget the ~)

* You might have this error:

Error: scp permission denied


Step 1. Don't panic.

Step 2. Use sudo before scp.

Step 3. Make sure the remote file folder's permission mode is okay such as:

$ sudo chmod 777 -R filefolder/
Step 4. Problem Solved.


No comments:

Post a Comment