This is a mirror of official site: http://jasper-net.blogspot.com/

How To Remotely Copy Files Over SSH Without Entering Your Password

| Tuesday, June 28, 2011
banner-019.png

SSH is a life-saver when you need to remotely manage a computer, but did you know you can also upload and download files, too? Using SSH keys, you can skip having to enter passwords and use this for scripts!

This process works on Linux and Mac OS, provided that they’re properly configured for SSH access. If you’re using Windows, you can use Cygwin to get Linux-like functionality, and with a little tweaking, SSH will run as well.
Copying Files Over SSH

Secure copy is a really useful command, and it’s really easy to use. The basic format of the command is as follows:

    scp [options] original_file destination_file

The biggest kicker is how to format the remote part. When you address a remote file, you need to do it in the following manner:

    user@server:path/to/file

The server can be a URL or an IP address. This is followed by a colon, then the path to the file or folder in question. Let’s look at an example.

    scp –P 40050 Desktop/url.txt yatri@192.168.1.50:~/Desktop/url.txt

This command features the [-P] flag (note that it’s a capital P). This allows me to specify a port number instead of the default 22. This is necessary for me because of the way I’ve configured my system.

Read more: How-to geek
QR: https://chart.googleapis.com/chart?chs=80x80&cht=qr&choe=UTF-8&chl=http://www.howtogeek.com/66776/how-to-remotely-copy-files-over-ssh-without-entering-your-password/

Posted via email from Jasper-net

0 comments: