xref: /original-bsd/old/berknet/net.1 (revision cfde0222)
Copyright (c) 1980 Regents of the University of California.
All rights reserved. The Berkeley software License Agreement
specifies the terms and conditions for redistribution.

@(#)net.1 6.1 (Berkeley) 04/29/85

NET 1 "04/29/85"
C 4
NAME
net - execute a command on a remote machine
SYNOPSIS
net [ -m machine ] [ -l login ] [ -p password ] [ -r respfile ] [ - ] [ -f ] [ -n ] [ -q ] command
DESCRIPTION
The net command sends the specified command (which should be enclosed in quotes) over the network to the specified (or default) remote machine. The network will notify the user when the command has been executed and will return to him any output or error indication by `writing' (see write (\*o)) to the terminal if he is still logged in, or `mailing' (see mail (\*o)) otherwise.

There are a number of options, which must precede the command. Options may be specified on the command line, preceding the command, or in a file ``.netrc'' in the user's login directory. The ``.netrc'' file is not described here. The -m option specifies the desired remote machine. If a remote machine is not specified, the default one is used. The machine name may be a one letter abbreviation or a full name; upper- and lower-case distinctions are ignored. If the standard output and standard error files are to be saved, the -r option returns to the originating user a file (respfile) containing the standard output and error files when the command was executed on the remote machine. If this option is used, no message is written back. The presence of a non-zero length respfile indicates completion. The -q option suppresses all acknowledgements unless an error occurs, there is output from the command, or the exit code of command is non-zero.

If the -l and -p options are not specified, and the login name and password are not in the ``.netrc'' file, a remote login name and password is prompted for on the terminal; the -f flag forces login name and password prompting. A single - indicates that the standard input from the local machine is to be taken and transmitted to the remote machine, where it will be the standard input for command. The -n flag forces all acknowledgment and output messages to be mailed rather than written on the terminal. Options do not need to be separated by spaces, i.e. either ``-m C'' or ``-mC'' is accepted. There are also other options intended to be used by higher level application programs and shell scripts only; they will not be described here.

The net command prepares a file to be sent to the remote machine and queues it in the `network queue.' Netq (\*s) gives information about the queues.

AUTHOR
Eric Schmidt
FILES
/usr/spool/berknet/logfile logfile with information about net activity

/usr/spool/berknet/plogfile? log file including packet transmission statistics

/usr/spool/berknet/netstat? statistics file

/usr/net/network.map local network names and topology

BUGS
-q should be the default.
"SEE ALSO"
netrm(\*s), netq(\*s), netlog(\*s), netcp(\*s), netlpr(\*s), netmail(\*s), netlogin(\*s), mail(\*o)

``An Introduction to the Berkeley Network", by Eric Schmidt