Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ rcp(1) — CLIX 3.1r7.6.28

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

ftp(1)

rcmd(1)

rlogin(1)

cp(1)

umask(1)

.rhosts(4)

services(4)

hosts.equiv(4)



  rcp(1)                              CLIX                              rcp(1)



  NAME

    rcp - Copies files between systems

  SYNOPSIS

    rcp [-p] file1 file2

    rcp [-p] [-r] file ... directory

  FLAGS

    -p   Preserves the modification times and modes of the source file in the
         destination file if the destination file does not already exist.  By
         default, the mode and owner of file2 are preserved if file2 already
         exists.

    -r   Copies each subtree rooted at each directory specified.  When this
         flag is used, the destination must be a directory.

  DESCRIPTION

    The rcp command copies files between systems.  Each file or directory
    argument is either a remote filename (in the form rhost:path) or a local
    filename.  Any colon (:) in the local filename must be preceded by a
    backslash (\).

    If file is not a full pathname, it is interpreted relative to the login
    directory on the remote host.  A file on a remote host can be quoted by
    enclosing the filename in double or single quotes ("" or ''), or preceding
    individual characters with a backslash (\).  This ensures the
    metacharacters are interpreted remotely.

    The rcp command does not prompt for passwords.  The remote username is
    assumed to be the same as the local username unless the remote file
    argument has the following form:

    ruser@rhost:path

    If the remote user's login account has a password, then the user must
    ensure that either the local host's fully qualified name (hostname plus
    domain name) is in the /etc/hosts.equiv file on the remote system, or that
    there is an entry in the .rhosts file in the remote user's home directory
    containing the local host's fully qualified name and (optionally) the
    username on the local host.

  EXAMPLES

    1.  The following copies mbox from the local host to host toad:

        rcp mbox toad:mbox



  2/94 - Intergraph Corporation                                              1






  rcp(1)                              CLIX                              rcp(1)



    2.  The following copies mbox from the local host to the remote host toad
        under the user login me:

        rcp mbox me@toad:mbox


    3.  The following copies mbox from the local host to the remote host toad
        and attempts to preserve the modification time and mode of the mbox
        file:

        rcp -p mbox toad:mbox


    4.  The following copies the files in the tree subdirectory on the local
        host to the tree subdirectory on the remote host toad:

        rcp -r tree toad:tree


  FILES

    .rhosts
           Remote user access list.

    .login Initialization file for csh when used as login shell.

    .cshrc Initialization file for csh.

    /etc/services
           Service name database.

    /etc/hosts.equiv
           Host equivalency name database.

  NOTES

    The rcp command does not detect all errors where a file is specified as
    the target of a copy when a directory should be the target.

    The rcp command is confused by any output generated by commands in a
    .login, or .cshrc file on the remote host.

  DIAGNOSTICS

    Permission denied.
           The .rhosts file on the remote host is not set up correctly.

    rcp: shell/tcp: unknown service
           The /etc/services file on the local host needs updating.

    rcp: lost connection



  2                                              Intergraph Corporation - 2/94






  rcp(1)                              CLIX                              rcp(1)



           The remote side of the connection went away unexpectedly.

    A usage message is displayed if an undefined flag is specified on the
    command line.

    Other error messages are prepended with rcp: and are related to system
    errors (open, read, write, and so on.)

  EXIT VALUES

    The rcp command exits with a value of 0 if successful.  If unsuccessful,
    it exits with a nonzero value.

  RELATED INFORMATION

    Commands:  ftp(1), rcmd(1), rlogin(1), cp(1), umask(1)

    Files:  .rhosts(4), services(4), hosts.equiv(4)




































  2/94 - Intergraph Corporation                                              3




Typewritten Software • bear@typewritten.org • Edmonds, WA 98026