LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Networking (https://www.linuxquestions.org/questions/linux-networking-3/)
-   -   How can I use scp (https://www.linuxquestions.org/questions/linux-networking-3/how-can-i-use-scp-434911/)

Jzarecta 04-13-2006 04:21 PM

How can I use scp
 
scp stands for secure copy, and is a tool from ssh, since I cant enable sftp because I dont have a ftp server. I want to do some file transfer with scp however the man doesnt include much syntax and examples.

So if I got a file on my computer that I want to copy to the server what will be the syntax?

scp local_file.txt 192.168.2.102/folder/subfolder

Is this correct, did I miss something?

puntjuh 04-13-2006 04:30 PM

Here is a page that'll help you with you're question.

http://www.die.net/doc/linux/man/man1/scp.1.html

pk21 04-13-2006 08:57 PM

scp local_file.txt YOUR_USERNAME@192.168.2.102:/folder/subfolder

Jzarecta 04-13-2006 11:11 PM

Quote:

Originally Posted by pk21
scp local_file.txt YOUR_USERNAME@192.168.2.102:/folder/subfolder

Thanks this is what I needed.

javaroast 04-13-2006 11:34 PM

Also you don't need an FTP server for SFTP. All you need is SSH. So you should be able to connect with SFTP as well as SCP.

Jzarecta 04-15-2006 12:27 AM

Interesting, i guess I kenw that but I wasnt aware of it. Gnome SFTP disk mount is exactly that. I will be able to work on this as soon as I get my system on again. Great stuff guys, thanks.

However can you give me a sample syntax on me using sftp, will it be the same of scp?

sftp local_file.txt USERNAME@192.168.1.xxx:/path/to/location

IBall 04-15-2006 02:52 AM

No, sftp has an interface similar to a standard command line ftp client:
Code:

sftp user@192.168.1.1
cd /path/to/location
put local_file.txt
bye

SFTP is provided when you install ssh - no need for any other servers or ports to be opened (other than 22).

--Ian


All times are GMT -5. The time now is 11:27 AM.