Switch to SpeakEasy.net DSL

The Modular Manual Browser

Home Page
Manual: (SunOS-4.1.3)
Apropos / Subsearch:
optional field

RCP(1C)                                                                RCP(1C)

       rcp - remote file copy

       rcp [ -p ] filename1 filename2
       rcp [ -pr ] filename...directory

       This  command  is  available  with the Networking software installation
       option.  Refer to for information on how to install optional software.

       rcp copies files between machines.  Each filename or directory argument
       is either a remote file name of the form:


       or a local file name (containing no `:' characters, or a `/' before any

       If a filename is not a full path name, it is  interpreted  relative  to
       your home directory on hostname.  A path on a remote host may be quoted
       (using \, ", or ') so that the metacharacters are interpreted remotely.

       rcp does not prompt for passwords; your current local  user  name  must
       exist on hostname and allow remote command execution by rsh(1C).

       rcp  handles  third party copies, where neither source nor target files
       are on the current machine.  Hostnames may also take the form


       to use username rather than your current local user name  as  the  user
       name  on the remote host.  rcp also supports Internet domain addressing
       of the remote host, so that:


       specifies the username to be used, the  hostname,  and  the  domain  in
       which  that  host resides.  Filenames that are not full path names will
       be interpreted relative to the home directory of the user  named  user-
       name, on the remote host.

       The destination hostname may also take the form hostname.username:file-
       name to support destination machines that are running older versions of

       -p     Attempt  to  give  each copy the same modification times, access
              times, and modes as the original file.

       -r     Copy each subtree rooted at filename; in this case the  destina-
              tion must be a directory.


       ftp(1C), rlogin(1C), rsh(1C)

       rcp  does  not  detect  all cases where the target of a copy might be a
       file in cases where only a directory should be legal.

       rcp can become confused by output generated by commands in a  .profile,
       .cshrc, or .login file on the remote host.

       rcp  requires  that the source host have permission to execute commands
       on the remote host when doing third-party copies.

       If you forget to quote metacharacters intended for the remote host  you
       get an incomprehensible error message.

                                  17 May 1989                          RCP(1C)