Communicator 3000 MPE/iX Release 6.0 (Platform Software Release C.60.00) (30216-90269)
212 Chapter 10
Technical Articles
The REMSH Client Functionality
Using REMSH
The REMSH service is accessed by running the REMSH.NET.SYS
program. You may do so under the MPE/iX CI or under the Posix shell.
While the format of the commands will differ depending on how you run
the program, the parameter list remains the same. We'll first look at
the parameters and then look at running the program under the Posix
Shell or from MPE/iX CI.
For the purposes of explaining the parameters, look at a sample
invocation from the Posix shell. Detailed examples of both the Posix
shell and MPE/iX invocations will follow later.
From the Posix shell you would invoke the REMSH by typing:
/SYS/NET/REMSH remotehost -l remoteuser remotecommand
In all cases you must provide a remotehost and a remotecommand. The
REMSH program will fail and generate an error message otherwise.
Unless the remote system has MPE/iX type userids, you will also need
to provide a -l remoteuser parameter as well. Otherwise the remote
system will not allow the connection.
remotehost is the name of the remote host you are attempting to
connect to. The host name can be either the official
name or an alias as understood by gethostbyname().
remoteuser is the userid on the remote system you wish to be.
NOTE The traditional UNIX implementation of REMSH makes the -l
remoteuser parameter optional. If you do not provide a -l remoteuser
parameter, REMSH takes your current userID and assumes that you
wish to connect to the same userID on the remote system. Since the
MPE version of the userID is USER.ACCOUNT, and the UNIX
equivalent is user, it is unlikely that you will find a user on the remote
system to match your id. We recommend that you always provide the -l
remoteuser argument to REMSH.
remote- command is the command that you wish to execute on the remote
machine. This command may be a CI command, a
program (that meets certain criteria) or a shell script. If
remotecommand is not specified, REMSH will terminate
and provide a usage message.
NOTE REMSH cannot be used to run commands that require a terminal
interface (such as VI) or commands that read their standard error (such
as more).
MPE/iX Examples
To run REMSH from MPE/iX prompt, type: