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

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

NETCP 1 "04/29/85"
C 4
NAME
netcp - remote copy of files through the net
SYNOPSIS
netcp [ -l login ] [ -p password ] [ -f ] [ -n ] [ -q ] fromfile tofile
DESCRIPTION
Netcp copies files between machines and is similar to cp (\*o). At least one of fromfile and tofile must be remote. The -l, -p, -f, -q, and -n behave exactly as in net (\*s).

Fromfile and tofile follow these conventions:

4 1. A simple filename is assumed to be local and from the current directory.

4 2. A filename preceded by a machine designator (see below) is a reference to a file on the specified remote machine. If a full pathname is not given, it is assumed to be from the login directory.

Examples:

" grades.p" 20
file in the current directory on local machine
" C:junk" 20
file in your login directory on C
" /usr/lib/pq" 20
file on local machine
" C:comp/c2.c" 20
file in a subdirectory on C machine

When files are being ``fetched'', that is, the fromfile is remote and the tofile is local, the tofile is created zero-length mode 600. For security reasons, when the ``fetched'' file's contents arrive at the local machine, the file must still be zero-length and mode 0600. No confirmation is sent to the user that the file has been ``fetched''; a non-zero file length indicates completion.

Netcp executes the net (\*s) command.

"SEE ALSO"
net(\*s), netrm(\*s), netq(\*s), netlog(\*s), netlpr(\*s), netmail(\*s), netlogin(\*s), cp(\*o), mail(\*o)
AUTHOR
Eric Schmidt
BUGS
The second filename may not be defaulted to a directory name as in cp (\*o), it must be given explicitly.

The file mode may or may not be set correctly.