Internet Services Berkeley (Communication between UNIX Systems)


Internet Services Berkeley (Communication between UNIX Systems)

Remote Copy ( rcp)

 

This program is used to copy files and directories from one UNIX system to another. To copy /tmp/krsort.c from system1 to system2, you could do the following:

 $  rcp   system2:/tmp/krsort.c  /tmp/krsort.c  

Some networking configuration needs to be made to files to get this level of functionality. In this example, the user who issues the command is considered "equivalent" on both systems and has permission to copy files from one system to the other with rcp . (These terms are described shortly).

Remote login (rlogin)

 

Supports login to a remote UNIX system. To remotely log in to system2 from system1, you would do the following:

 $  rlogin system2  password: Welcome to system2 $ 

If a password is requested when the user issues the rlogin command, the users are not equivalent on the two systems. If no password is requested, then the users are indeed equivalent. You can also issue rlogin system -l user to specify the system and user as part of the command.

Remote shell (remsh)

 

With the remsh command, you can sit on one UNIX system and issue a command to be run remotely on a different UNIX system and have the results displayed locally. This command is called rsh on Linux and some other UNIX variants. In this case, a remsh is issued to show a long listing of /tmp/krsort.c . The command is run on system2, but the result is displayed on system1, where the command was typed:

 $  remsh system2 ll /tmp/krsort.c  -rwxrwxrwx 1 root sys 2896 Sept 1 10:54 /tmp/krsort.c $ 

In this case, the users on system1 and system2 must be equivalent, or else permission is denied to issue this command.

Remote who (rwho)

 

Find out who is logged in on a remote UNIX system. Here is the output of issuing rwho :


$   rwho
root              system1:ttyu0              Sept  1  19:21
root              system2:console          Sept  1  13:17
tomd              system2:ttyp2              Sept  1  13:05
                                                                         >  time  of  login
                                                           >  day  of  login
                                       
                                       >  terminal  line
                         >  machine   name

>  user  name

For rwho to work, the rwho daemon ( rwhod ) must be running.

Other "r" commands, in addition to those covered are available. Also, variations of these commands occur going from one UNIX variant to another, so you may not run exactly the same "r" command on your UNIX system.



HP-UX 11i Systems Administration Handbook and Toolkit
HP-UX 11i Systems Administration Handbook and Toolkit (2nd Edition)
ISBN: 0131018833
EAN: 2147483647
Year: 2003
Pages: 301

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net