Introduction to Unix

../_images/ksus3.jpg ../_images/UNIX_blocks3.jpeg

6.2. Communication Between Hosts

Linux for Programmers and Users, Section 9.6

Here we list two commands for copying files betweens host (rcp and scp) and two commands to remotely use a remote host (rsh and ssh). The commands rcp and rsh are not secure (data is not encrypted), while scp and ssh are secure. Only secure communication commands should be run on networks, such as over the Internet, where untrusted users might be present.

It is possible with both the secure and unsecure versions of these programs to use them without the needed to type a password. The scp and ssh programs do so using public and private key files. Instructions for how to set this up can be found on various web pages on the Internet.

6.2.1. rcp

rcp

Copy file(s) between hosts.

6.2.2. scp

scp

Secure copy file(s) between hosts.

6.2.3. rsh

rsh

Run a command (including a shell) on a remote computer.

6.2.4. ssh

ssh

Securely run a command (including a shell) on a remote computer.

SYNOPSIS

ssh [userid@]hostname [command]

When not command is run on the remote host a login is attempted.

With both rsh and ssh, in addition to running a command on a remote computer, data may be passed over the communication channel. See dd for some examples.